TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #85 · 15 мај

"Ну и как же нам перекидывать строки ви числа?" спросите вы. Проверять каждый символ, очистив строку от лишних знаков и точек. Потом конвертить допустимые символы в числа и восстанавливать знак, дробную чусть и тд??? Самый быстрый способ это просто "попробовать" 😜 text = "-0.3" try: num = float(text) except ValueError: print('Dough!') Всё остальное это уже парсинг и разбор символов для иных целей. #basic

Hashtags

Резултати

Пронајдени 1 слични објави

Пребарај: #gettext

当前筛选 #gettext清除筛选
djangoproject

@djangoproject · Post #433 · 07.09.2017 г., 11:11

https://docs.python.org/3/library/gettext.html The #gettext module provides internationalization (#I18N) and localization (#L10N) services for your #Python modules and applications. It supports both the #GNU gettext message catalog #API and a higher level, class-based API that may be more appropriate for Python files. The interface described below allows you to write your module and application messages in one natural #language, and provide a catalog of #translated messages for running under different natural languages. Some hints on localizing your Python modules and applications are also given.