4 ms·
You're right. I didn't mean to imply that Big-O is useless. I'm reminded on an incident in the 1990s, when I was an instructor teaching C at the local telco,
by wpollock 1y ago
You're right. I didn't mean to imply that Big-O is useless.
I'm reminded on an incident in the 1990s, when I was an instructor teaching C at the local telco, when a student showed me a (COBOL) program that had stumped his programming team. It would always hang their computer when it was run. What caught my eye was the main loop was nested seven levels deep, and each loop ran 50,000 iterations. Their computer wasn't hung, they only needed to wait a decade or so for the computation to finish!
Big-O knowledge made the error obvious to me, and I added that to the curriculum for all programming courses I could.
- namibj 1y ago(on the order of) 110 bits of brute-force isn't anywhere close to "a decade" especially if you aren't throwing severe parallelism at it. Edit: we're talking on the order of a million times the current age of the universe if you have a multi-GHz CPU and only take one cycle for each inner iteration.
- wpollock 1y ago50000^7 ÷ 100000000 = ~2.5E17 years. That's a long time!