Skip to content

Comment on Alphabetically sorting business cardsparent

Comments

Well, now that you mention it, yes. When it became around 3-5 cards per stack it was quicker to use insertion sort. I found out, that like computers, it's ultimately a tradeoff between desk space(RAM) and stack iteration (CPU) by me.

I haven't tried radix sort - I'll go try it today and see how well I do. Nope, I don't do selection sort either, since it's quicker to perform insertion sort when stack size gets manageable.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.