Пример: def tricky(x): return x * 2 + 1 if x > 0 else x - 1
explain_bytecode(tricky)
Этот хак показывает байткод Python-функции, позволяя заглянуть под капот интерпретатора. Используется для:
• отладки «странного» поведения функций • анализа производительности на уровне Python VM • изучения, как Python интерпретирует тернарные выражения, замыкания, генераторы и т. д.
Модуль dis встроен в стандартную библиотеку и часто игнорируется — но это мощный инструмент для продвинутых разработчиков и авторов интерпретаторов.
Пример: def tricky(x): return x * 2 + 1 if x > 0 else x - 1
explain_bytecode(tricky)
Этот хак показывает байткод Python-функции, позволяя заглянуть под капот интерпретатора. Используется для:
• отладки «странного» поведения функций • анализа производительности на уровне Python VM • изучения, как Python интерпретирует тернарные выражения, замыкания, генераторы и т. д.
Модуль dis встроен в стандартную библиотеку и часто игнорируется — но это мощный инструмент для продвинутых разработчиков и авторов интерпретаторов.
Telegram is a free app and runs on donations. According to a blog on the telegram: We believe in fast and secure messaging that is also 100% free. Pavel Durov, who shares our vision, supplied Telegram with a generous donation, so we have quite enough money for the time being. If Telegram runs out, we will introduce non-essential paid options to support the infrastructure and finance developer salaries. But making profits will never be an end-goal for Telegram.
Telegram hopes to raise $1bn with a convertible bond private placement
The super secure UAE-based Telegram messenger service, developed by Russian-born software icon Pavel Durov, is looking to raise $1bn through a bond placement to a limited number of investors from Russia, Europe, Asia and the Middle East, the Kommersant daily reported citing unnamed sources on February 18, 2021.The issue reportedly comprises exchange bonds that could be converted into equity in the messaging service that is currently 100% owned by Durov and his brother Nikolai.Kommersant reports that the price of the conversion would be at a 10% discount to a potential IPO should it happen within five years.The minimum bond placement is said to be set at $50mn, but could be lowered to $10mn. Five-year bonds could carry an annual coupon of 7-8%.