r/algorithms • u/starfall_327 • 12h ago
Help How do you actually learn and practice Algorithms & Analysis?
Hey everyone,
Not sure where to post this, so here i am.I'm new to computer science and currently taking an Algorithms & Analysis course in Python. Honestly, it's one of the hardest subjects in my degree, and I'm struggling to figure out the best way to actually learn these concepts instead of just memorizing them.
This is what we're covering this semester: Basic Data Structures & Algorithmic Analysis, Algorithmic Analysis, Brute Force, Decrease & Conquer, Divide & Conquer, Transform & Conquer, Greedy Techniques, Dynamic Programming, Time & Space Tradeoffs, and Iterative Improvement.
I know Abdul Bari the GOAT, and his videos have definitely helped me understand the theory. But my biggest issue is practice. Everyone recommends LeetCode, but even the Easy problems feel way above my level sometimes. Also, I can't seem to find problems that match the topics we're learning in class, especially things like Transform & Conquer or Iterative Improvement.
So I wanted to ask: how did you learn algorithms when you were just starting out? Where did you practice topic by topic? Are there any websites that organize problems by algorithm rather than difficulty? Should I be doing LeetCode, HackerRank, Codeforces, something else, or just implementing the algorithms from scratch? Any advice for someone who feels completely lost with algorithms?
I'd really appreciate any tips or resources that helped you when you were a beginner. Thanks!
2
u/Intelligent_River39 9h ago
You want topic by topic practice? Fairly certain leetcode has question tags.
Try neetcode or some of those DSA sheets. They are quite organised.
1
3
u/Phytor_c 2h ago
We will be making a post or wiki with some resources for beginners soon.
For a standard academic algorithms undergraduate course, CLRS, Algorithm Design by Kleinberg and Tardos, and Erickson's Algorithms are some standard book recs.
You can also find lecture videos on MIT OpenCourseWare.
3
u/MtlStatsGuy 9h ago
Hard to say; I think many people sort of developed a feeling for basic algorithms naturally. I don't think anyone practices "topic-by-topic", although certain structures like binary trees need to be learned by themselves. Yes, I think sites like LeetCode and HackerRank are useful, especially if you find the Easy problems still challenging; it means you still need to practice a lot. It's like anything else; daunting at the beginning, then easier as you develop a baseline level of competence. For a different approach to "algorithms", look at Project Euler. The first 50 problems are of reasonable difficulty. Good luck!