Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Unbounded integer types exist, which have infinite precision in theory and are only limited by available memory in practice.

You can make the argument that "proper" integers are also bounded in practice by limitations of our universe :)



Unbounded integer types aren't ints.

The important point is that the arithmetic operators on int perform modulo arithmetics, not the normal arithmetics you would expect on unbounded integers. This is often not explained when first teaching ints.


In many langue’s (e.g. Python, so not even obscure languages), ints are unbounded.


That’s not the notion of ints the article, nor GP by “computer ints”, was referring to. Python is rather atypical in its nomenclature here. Arbitrary-precision integers are generally called “integer” or something like “bigint”.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: