Articles
The idea
A CSV file is a text file where each line is a row and each value is separated by a comma.
That's it. No special format, no proprietary software. Just commas and newlin…
What you're building
A daily notes logger. The user writes a note. It gets saved — with a timestamp — to a text file. Every note appends to the same file. Nothing is …
What you're building
The shopping list is back. Again.
Version 1 used a list. Version 2 added quantity and price with a dict.
Version 3 adds persistence. The list saves to a fi…
You've covered file handling from every angle. Here are the mistakes that show up most often — and how to fix them.
1. Not closing the file — or forgetting with open(…
You've covered file handling from every angle. Before moving on, here's everything in one place.
// The pattern — always
with open("file.txt", "r", encoding="utf-8") as f:…
Stop for a second.
Look at what's in your kit now.
Lists that grow, shrink, sort, and remember. Dicts that give you any value by name — instantly. Tuples that hold fixed d…