HACKER Q&A
📣 baalimago

Know algorithms, or know how to implement them?


I'm playing around doing leetcode challenges for fun where I stumbled upon one which required quicksort. It struck me then that I've completely forgotten how to implement it (which I once did a couple of years ago at uni), I had to go to wikipedia and write it from pseudo code. All in all it took me about 30 min to solve.

This got me thinking; is this even an issue? Is there value in knowing algorithms like quicksort and Djikstra's by heart, as opposed to being confident that you're able to implement them given information on how to do it?


  👤 bradwood Accepted Answer ✓
What's more important is knowing how to analyse/derive the big-O of each of the various algorithms in space and time, IMHO.