   Longer Than Long - Need Help
  Hey everyone. I''m working on a C++ program that uses huge integers, up to 10^15 or so. However, I don''t know of any data type that allows me to use integers that large. Is there anything I could download that would give me access to something like this, or some other way I could use numbers this large? Thanks for you help! 
  Well, a 64 bit integer will give you 264 (18446744073709551616) possibilities.  That is the ''long long'' or the ''__int64'' type.If you need more than that, then there are various classes available that let you handle extremely large numbers.Google: Large Number Class.John B ;  I tried using both long long and __int64 in the variable definition, but it would never let me output the value. I would get a compiling error saying "''operator <<'' is ambiguous". ;  Write your own "integer" class, using strings internally: class HugeInt{private:  std::string internalRep;  std::stringstream converter;  static const char * digits[] =    { "0", "1", "2", "3", "4", "5", "6", "7", "8", "9" };  static std::map<const char *, int> reverseLookup; public:  HugeInt(int i)  {    converter("");    converter << i;    internalRep = converter.str();  }   // More constructors...   HugeInt operator+ (const HugeInt & i)  {    // per-digit addition  }   // More operators...};;  There's a library called CLN (Class Library for Numbers) that's kinda what you want.[edit]Whoops, forgot to tell you where to find it.  here [edited by - Flarelocke on February 14, 2004 9:02:04 PM]