Python

TL;DR: Python statement from module import obj creates a copy of the object in the importing scope. In other words, from module import obj is roughly equivalent to obj = __import__(‘module’).obj. […]

Creation of Python packages underwent a few significant changes in the last 3-4 years. Here’s my note to self to remember what was changed/deprecated when: “Eggs”  => “Wheel“ “Eggs” was […]

Code: https://github.com/ikriv-samples/logarthmic-fibonacci. Fibonacci sequence is defined as a sequence starting with 0, 1 where each subsequent member is calculated as fib(n) = fib(n-1)+fib(n-2). This yields an infinite sequence 0, 1, […]

In Python,  async for uses asynchronous generator to iterate over values. But how is it different from a regular for that uses a generator that yields awaitables? TL;DR: not much, […]

Coming from C# background, I was trying to understand whether Python allows to pass obj.method where ordinary function is expected, and if yes, how could it possibly work. Consider this […]