1 ans1=0.1+0.2 2 print(f'0.1+0.2={ans1}') 3 4 import decimal 5 6 ans2=decimal.Decimal('0.1')+decimal.Decimal('0.2') 7 print(f'0.1+0.2={ans2}')