What is your favorite Python syntactic sugar?
The thing I love about python is it's elegance; and I thing that is partially due to its syntactic sugar. Between list comprehensions, destructuring, enumerators, generators with yield, and a bunch more, what is your favorite
Generators probably. It's the one thing i genuinely miss about python when i work in rust.
You're right. Having just yield sth in a function instead of defining the data structure is such a game changer.
yield sth
Decorators are one of most useful features I'm using most frequently.
Yeah, I'm just learning about decorators in classes, and they're super cool!