Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple APILearn More
ilechuks7332933dI don't have the slightest idea of what this is? I feel dumb
kiki1697333dNice! Do big-o’s match?
AmyShackles404633d@uyouthe I would be surprised if they didn’t.
RememberMe1435432dHeaps/heapsort is probably my favourite data structure/sorting algorithm combination. It's just so satisfying.
AmyShackles404631d@RememberMe It took me way too long to understand why Floyd’s Heap Construction works. I could figure out why you end at position 1, but couldn’t figure out why in the hell you start from the size of the array integer divided by two. So.... drew different sized trees to try to figure out the pattern. Felt like a fucking idiot when the answer was “ah, it is the index of the last parent node”.
faheel296826dNice work! I'll take this as an inspiration to implement graphs and trees in a few different languages that I commonly work with. It's something I've been putting off for quite a while.