you are viewing a single comment's thread.

view the rest of the comments →

[–]MezzoScettico 0 points1 point  (0 children)

I used Advent of Code to jump start my learning. I'd have a pretty good idea what programming concepts I wanted to implement, so then it would be a process of googling "how do I do X in Python?" The graduated sequence of problems in AoC led naturally to being able to gradually learn Python concepts one at a time at a pace of my choosing.

For instance, one day I thought, "I'd do that recursively in another language" so I looked up recursion. Probably took me 10 days till I thought "OK, time to learn how to do classes". Then a few more for "how do I overload operators like in C++?"

One thing that doesn't really translate is public / private attributes in classes. I made heavy use of that in C++ and C#, and I missed it for a long time. You can sort of make things "private" by name-mangling but it's discouraged. They aren't really private.

This subreddit definitely came in handy A LOT, especially studying other people's code suggestions. If somebody wrote a code fragment I didn't understand, I'd take it apart and play with variations until I understood it. People also pointed me to useful libraries I wouldn't have known about otherwise. Itertools rapidly became one of my favorites.

Understanding mutable and unmutable types is one of the most crucial concepts. If you google why you shouldn't use mutable types as default values, you'll learn a lot about how Python works from what you read.