Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's really funny, but when I see an error that's a power of 2, I immediately look for a hardware bug.


Exactly. The 64 is no coincidence.


I once introduced a bug that squared each customer's order quantity.

Order 8 of the thing, we shipped 64. Oops.

Nutshell: The items were sold in bundles. To arrive at the quantity to ship, you multiply the quantity of bundles ordered by the quantity of each item in the bundle (just 1 or 2 in most cases). I got my variables confused and multiplied the order quantity by itself.

Not my best day.


I once saw this in a downstream system that if an order was entered calculated price with the square of the quantity.

And the order in question was for 1000 400oz bars of gold (value $700k each).


This can be hard to notice as the square of one is one.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: