Search code examples
c++numeric-limits

How do games/programs calculate numbers higher than limits in C++?


If all types of values (ints, floats, etc.) have limitations, how do programs like excel or games calculate numbers higher than these? Do the companies create their own proprietary calculators? Are there standard libraries that handle this?

edit: clarity


Solution

  • By using "arbitrary precision" math libraries like Gnu MP Bignum Library. These libraries get around physical limitations of the hardware by using algorithms to combine multiple ints, floats, chars etc to represent and operate on a single number.