What’s an Integer?
If you have the natural numbers and you want the integers, all you have to do is add an additive inverse. If you understand the naturals and want to understand the integers, you also only need to add one thing: direction. If you think of a number line, the natural numbers start from zero and go to the right, but there’s nothing to the left of zero. Integers start with the naturals and add negative numbers moving to the left on the other side of zero.
The meaning of integers follows from the notion of direction. Positive integers mean the same thing as the natural numbers, both as cardinals and as ordinals. Negative numbers allow you to move in the other direction. If you think in terms of cardinals, integers allow you to ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access