#python #sicp
int objects represent
integers exactly, without any approximation or limits on their size. On the
other hand, float objects can represent a wide range of fractional numbers,
but not all numbers can be represented exactly, and there are minimum and
maximum values. Therefore, float values should be treated as approximations
to real values.
If you want to change selection, open document below and click on "Move attachment"
2.1 Introductionming languages: a "floating point"
representation. While the details of how numbers are represented is not a
topic for this text, some high-level differences between int and float
objects are important to know. In particular, <span>int objects represent
integers exactly, without any approximation or limits on their size. On the
other hand, float objects can represent a wide range of fractional numbers,
but not all numbers can be represented exactly, and there are minimum and
maximum values. Therefore, float values should be treated as approximations
to real values. These approximations have only a finite amount of precision.
Combining float values can lead to approximation errors; both of the
following expressions would evaluate to 7 if not fo Summary
status | not read | | reprioritisations | |
---|
last reprioritisation on | | | suggested re-reading day | |
---|
started reading on | | | finished reading on | |
---|
Details