The `str.translate()` method accepts a table of codepoints mapped to another character or codepoint. Map to `None` for characters that have to be deleted. You can use the `ord()` built-in function to get the codepoint of characters. Or, you can use the `str.maketrans()` method to generate the mapping for you.
This video is based on content from my "100 Page Python Intro" ebook: https://github.com/learnbyexample/100...
На этой странице сайта вы можете посмотреть видео онлайн Python tip 15: string transliteration длительностью часов минут секунд в хорошем качестве, которое загрузил пользователь learnbyexample 23 Август 2022, поделитесь ссылкой с друзьями и знакомыми, на youtube это видео уже посмотрели 256 раз и оно понравилось 1 зрителям. Приятного просмотра!