Ahmad Echem
Ahmad Echem

Reputation: 111

An Javascript error toFixed round problem

I have an issue about toFixed method.

When i run this code 1.535.toFixed(2) The result is 1.53. But when i run this code 2.535.toFixed(2) The result is 2.54 so it rounded. How it is possible?

1.535.toFixed(2) this result should be 1.54 not 1.53

Upvotes: 0

Views: 19

Answers (0)

Related Questions