udemypython:numbers-faq

  1. What's the difference between floating point and an integer?

An integer has no decimals in it, a floating point number can display digits past the decimal point.

  1. Why doesn't 0.1+0.2-0.3 equal 0.0 ?

This has to do with floating point accuracy and computer's abilities to represent numbers in memory. For a full breakdown, check out: https://docs.python.org/2/tutorial/floatingpoint.html

  • udemypython/numbers-faq.txt
  • ostatnio zmienione: 2022/05/22 10:38
  • przez 127.0.0.1