Hacker News new | ask | show | jobs
by Bostonian 1048 days ago
I assume for most programming languages there is no speed difference in writing

   y = x/5.0
vs.

   y = 0.2 * x
Is that true?
1 comments

Yes, but computing an integer into it's reciprocal (which is what you're doing in decimal) is the computation that makes it more complex, you're just offloading that from the machine to your head. Try doing this with x/31, show me the operation to convert 31 into it's reciprocal in decimal and you'll see where the complexity lies.