Table of Contents

Python - Float Numeric

About

floats (fractional numbers written with a decimal point, like 1.970),

Initialization

my_float = 1.23

For arithmetic over R (Rational), Python uses floats, so round-off errors occur:

>>> 10.0**16 + 1 == 10.0**16
True

Consequently algorithms such as do not find exactly correct solutions.