TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Python f-strings can do more than you thought. f'{val=}', f'{dt:%Y-%m-%d}'

3 pointsby abbassiover 3 years ago

1 comment

abbassiover 3 years ago
f-strings in Python are not just a way to easily substitute variables inside strings, they come with a wide array of conversion, formatting, and debugging options which we give examples of in this video.<p>Note: I&#x27;m trying a more informal style in this video so make sure to let me know if you like it better this way, as opposed to my usual cut-after-every-sentence editing.
评论 #28954385 未加载