Many languages are not strongly typed (where "strongly typed" means "variables must be predeclared with their types (though they may be inferred)"). If your only experience is with strongly-typed languages, then MANY things about Python will be different, because Python is one of many languages that is not strongly typed.
For example, in Scheme (a Lisp), a division (/) presented with exact input values and a non-zero denominator will produce an exact value (an integer or rational). E.g., (/ 1 2) produces the exact fraction 1 divided by 2, and not 0.
In addition, both Scheme and Python have different ideas of what an "integer" is, e.g., both are happy to compute the exact value of 2 to the 9999 power. There's no requirement that "integer" correspond to the underlying machine integer.
dwheeler|7 years ago
For example, in Scheme (a Lisp), a division (/) presented with exact input values and a non-zero denominator will produce an exact value (an integer or rational). E.g., (/ 1 2) produces the exact fraction 1 divided by 2, and not 0.
In addition, both Scheme and Python have different ideas of what an "integer" is, e.g., both are happy to compute the exact value of 2 to the 9999 power. There's no requirement that "integer" correspond to the underlying machine integer.
kjeetgill|7 years ago
Python is strongly typed but not staticly. Weak typing is more like 1 == "1" is true. Aka implicit parsing or casting.
unknown|7 years ago
[deleted]
emmelaich|7 years ago
Nobody doing maths with pencil or paper will think 3/2 equals 1.
More to the point, the symbol 1 represents a float as much as it does an integer.