A

Admin • 833K Points
Coach

Q. What will console.log(0.1 + 0.2 == 0.3) print?

  • (A) false
  • (B) true
  • (C) undefined
  • (D) NaN
  • Correct Answer - Option(A)
  • Views: 16
  • Filed under category JavaScript
  • Hashtags:

Explanation by: Admin

Due to floating-point precision, 0.1 + 0.2 is not exactly 0.3.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.