+ 2

var num1=0.1 var num2=0.2 var num3=0.3 Console.log(num1+nun2 == num3)

what is the result ??

27th Jan 2018, 1:10 PM
Demi Louka
Demi Louka - avatar
2 Answers
+ 1
The result is false because in JavaScript 0.1 + 0.2 = 0.3000000000000004.
27th Jan 2018, 1:27 PM
Jonathan Pizarra (JS Challenger)
Jonathan Pizarra (JS Challenger) - avatar
+ 1
thanks now i understand
27th Jan 2018, 1:28 PM
Demi Louka
Demi Louka - avatar