Zen of Python
Полный Дзен Пайтона в одном канале Разместить рекламу: @tproger_sales_bot Правила общения: https://tprg.ru/rules Другие каналы: @tproger_channels Сайт: https://tprg.ru/site Регистрация в перечне РКН: https://tprg.ru/xZOL
Show more📈 Analytical overview of Telegram channel Zen of Python
Channel Zen of Python (@zen_of_python) in the Russian language segment is an active participant. Currently, the community unites 18 938 subscribers, ranking 6 785 in the Technologies & Applications category and 34 730 in the Russia region.
📊 Audience metrics and dynamics
Since its creation on невідомо, the project has demonstrated rapid growth, gathering an audience of 18 938 subscribers.
According to the latest data from 31 August, 2026, the channel demonstrates stable activity. Although there has been a change in the number of participants by -151 over the last 30 days and by -7 over the last 24 hours, overall reach remains high.
- Verification status: Not verified
- Engagement rate (ER): The average audience engagement rate is 10.84%. Within the first 24 hours after publication, content typically collects 6.11% reactions from the total number of subscribers.
- Post reach: On average, each post receives 2 053 views. Within the first day, a publication typically gains 1 157 views.
- Reactions and interaction: The audience actively supports content: the average number of reactions per post is 4.
- Thematic interests: Content is focused on key topics such as github, rust, pip, api, install.
📝 Description and content policy
The author describes the resource as a platform for expressing subjective opinions:
“Полный Дзен Пайтона в одном канале
Разместить рекламу: @tproger_sales_bot
Правила общения: https://tprg.ru/rules
Другие каналы: @tproger_channels
Сайт: https://tprg.ru/site
Регистрация в перечне РКН: https://tprg.ru/xZOL”
Thanks to the high frequency of updates (latest data received on 01 September, 2026), the channel maintains relevance and a high level of publication reach. Analytics show that the audience actively interacts with content, making it an important point of influence in the Technologies & Applications category.
VOWELS_LOWERCASE = set('aeoiuаоыуэяёиюе')
def invert_vowels(strng):
reversed_vowels = (i for i in strng[::-1] if i.lower() in VOWELS_LOWERCASE)
return ''.join([i if i.lower() not in VOWELS_LOWERCASE else next(reversed_vowels) for i in strng])
и @HackingSection:
def invert_vowels(s, vowels = "аяоёиыуюеэ"):
vowelsInText = [j for j in s if j in vowels]
return [vowelsInText.pop(-1) if i in vowels else i for i in s]
Отдельный респект Cool and Fun Python за разбор своего решения:
Предполагается, что все буквы в тексте строчные и русские. Иначе требуется доработать строку гласных.
У решения линейная асимптотика. Но если очень хочется, можно повысить быстродействие, превратив vowels в множество строк односимвольников: vowels = {'а', 'я', ...}
И преобразование строки в список и обратно - вынужденная мера. Строка в Python неизменяемая. Впрочем, на сохранение асимптотики O(N) это не влияет.
Кстати, если бы постановщик задачи гарантировал наличие гласных (всё же предлоги "в", "с" тоже считаются словами), можно было бы убрать проверки left < right в двух внутренних циклах.
Отдельная благодарность @lomserman за создание тестирующей функции:
def test(original: str, expected: str):
result = invert_vowels(original)
print(result)
assert result == expected
p.s. Админ подписывается на всех ребятушек, что решают задачи. Если «провалиться» в профили решивших, там полно питонической годноты.
#задача
@zen_of_pythons и t . Напишите функцию проверки: является ли s подстрокой t.
Подстрока формируется из исходной строки путём удаления некоторых символов (может быть, ни одного) без нарушения положения остальных. "ace" является подстрокой "abcde", а "aec" — нет.
Ограничения:
0 <= len(s) <= 100
0 <= len(t) <= 10^4
s и t состоят только из строчных английских букв.
В качестве теста:
s = "abc"
t = "ahbgdc"
>>> is_substring(s, t)
... true
#задача
@zen_of_python| Библиотека | Сжатие, разы |
|------------|--------------|
| zlib | 27.84 |
| lz4 | 18.23 |
| brotli | 64.78 |
| zstandard | 43.42 |
Остальные «пьедесталы» плюс данные о дизайне экспериментов в треде. Сжимали .json.
#факты
@zen_of_pythonx = lambda s: (s**(1/2)).is_integer()
@nxiqns:
def check_square_perfection(num):
return (num**0.5).is_integer()
и @WhonixMan:
def check_square_perfection(num):
return int(num**0.5) == num**0.5
Отдельно выделим решение @maslyaev, учитывающее случай очень больших чисел:
def check_square_perfection(area: int | float) -> bool:
if area == 0 or area == 1: # На 0 и 1 ломается вавилонский метод
return True
if area < 4: # Отрицательная area даст False
return False
if area % 1 != 0: # Нецелая area даст False
return False
int_area = int(area)
sqrt = int_area // 2
while True:
next_sqrt = (sqrt + int_area//sqrt)//2
if next_sqrt == sqrt:
break
sqrt = next_sqrt
return sqrt * sqrt == int_area
#задача
@zen_of_python>>> s = 'погода'
>>> invert_vowels(s)
... пагодо
#задача
@zen_of_python