Possible Duplicate:
Representing 128-bit numbers in C++
I need a way to store a 128 bit number, is there something besides unsigned long long that I can use?
Possible Duplicate:
Representing 128-bit numbers in C++
I need a way to store a 128 bit number, is there something besides unsigned long long that I can use?
You may want to use the GNU Multiple Precision Arithmetic Library.
There's no primitive type for that.
Vlad's comment is a good solution for storage, but if you need to use that number for computations, you'll need to use a library allowing representation and arithmetic operations on big numbers.
You should start by taking a look at GMP:
If you only need to store it then you can store it in a byte array like "char num128[16]".
If you need to manipulate it you need to use big numbers library like GMP.
It is not possible to store it in one primitive data type, so we have to be slightly more creative. Probably the easiest way to do it is to have the class hold two 64-bit ints, representing the upper and lower halves of the integer.