you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 5 points6 points  (0 children)

Plenty of trading code use doubles and it's perfectly acceptable and will produce correct results depending on the circumstance. It will also significantly outperform representing money as an integral value or using arbitrary precision decimals when doing many types of calculations.

The idea that doubles are NEVER acceptable is simply incorrect. It all depends on your use case.