Should I implement every machine learning algorithm from scratch to gain a deeper understanding?

I’ve completed C1 of this course, but when I tried to implement the models on my own from scratch without looking at the course code I completely hit a wall. I understand the theory and the mathematical equations behind the models, but I still struggled to turn that understanding into working code.

Because of that, I’m revising the entire C1 content before moving on to C2.

My question is: should I implement every machine learning algorithm from scratch to gain a deeper understanding?

Using libraries and simply passing data to built-in functions is obviously much more efficient in terms of time and effort, but it can sometimes feel like I’m just feeding inputs into a black box. Since I already have programming experience and can generally understand what the code is doing, I’m wondering whether implementing algorithms from scratch would be the best way to learn, or if there’s a more effective approach.

What would you recommend?

edit: I’ve used AI to help fix my broken english grammer. English is not my first language :frowning:

This is a matter of your goals and your personal learning style.

AI is a tool. Like a hammer, sometimes it’s good to know how to make your own hammer. Sometimes you only need to drive a nail.