Python f-strings are impressive! Did you know you can use f-strings to string format almost anything in Python? You can use them to format floats, multiline strings, decimal places, objects and even use if-else conditionals within them. In this pos...

Markdown supported · ⌘↵ to post
So much stuff you can do! I'll certainly take notes of them all. Thanks for the great content.
Martin Bless
Punch card programmer
Wow, thanks for the plethora of examples. One thing I'm missing: What about "nested" variable substitution like
>>>b = 15 >>>c = 5 >>>f"{2/3:{b}.{c}}" ' 0.66667'Maybe you would like to explore and think that through as well? That would make your blog post perfect for me.