Why False | Sololearn: Learn to code for FREE!

+2

Why False

Why 0.1+0.2==0.3 Output is false

6/16/2020 2:45:00 PM

Mohammad

2 Answers

New Answer

+3

Because 0.1 +0.2 = 0.300000004 != 0.3

0

Try this for comparision upto 2 decimal places, print(round(0.1+0.2,2)==0.3)