I need some help, heh, i have to store a twelve digit number somewhere... as i've understood it nothing like unsigned int or long double or anything won't work
have i missed something? or can anyone point me to anything which i can use to be able to do this?... i have to be able to performe calculations on that number too... 
i'm using c++ by the way.
Not the most trivial program. We had a similiar problem like this in a programming content many years ago. I still have the source, so take a long, and it should help. It stores big numbers, up to 100 numbers if I remember correctly. There is no type for what you want to do. You gotta use strings.
#include <iostream>
#include <cstdlib>
#include <cstring>
using namespace std;
#include <fstream.h>
void Simulation();
void Reverse( int * );
void PrintNums( int * );
void NullifyMemory( char *, char * , char *, int * );
void FillArrays( char *, char *, char * );
void ComputeSum( char *, char *, int * );
enum Restrictions { FRestriction = 50, SRestriction, TRestriction = 101 };
const int ModFactor = 10;
ifstream infile("E:\\largenum.txt");
int main()
{
Simulation();
system("PAUSE");
return 0;
}
void Simulation()
{
char nums[ TRestriction ] = { '\0' };
char num1[ FRestriction ] = { '\0' };
char num2[ FRestriction ] = { '\0' };
int sum[ SRestriction ] = { 0 };
while ( infile.getline( nums, TRestriction, '\n' ) )
{
FillArrays( nums, num1, num2 );
ComputeSum( num1, num2, sum );
Reverse( sum );
PrintNums( sum );
NullifyMemory( nums, num1, num2, sum );
}
}
void Reverse( int sArr[] )
{
int temp = 0;
int limit = FRestriction;
for ( int i = 0; i < SRestriction / 2; ++i )
{
temp = sArr[ i ];
sArr[ i ] = sArr[ limit ];
sArr[ limit-- ] = temp;
}
}
void PrintNums( int outArr[] )
{
bool FoundNonZero = false;
for ( int i = 0; i < SRestriction; i++ )
{
if ( outArr[ i ] > 0 )
FoundNonZero = true;
if ( FoundNonZero )
cout << outArr[ i ];
}
cout << endl;
}
void NullifyMemory( char _nums[], char _num1[], char _num2[], int _sum[] )
{
for ( int i = 0; i < TRestriction; i++ )
_nums[ i ] = '\0';
for ( int i = 0; i < FRestriction; i++ )
_num1[ i ] = _num2[ i ] = '\0';
for ( int i = 0; i < SRestriction; i++ )
_sum[ i ] = 0;
}
void FillArrays( char _nums[], char _num1[], char _num2[] )
{
int sizeString = strlen( _nums );
int i = 0;
for ( i = 0; i < FRestriction && _nums[ i ] != ','; i++ )
_num1[ i ] = _nums[ i ];
i++;
int j = 0;
while ( i <= sizeString && _nums[ i ] != '\n' )
_num2[ j++ ] = _nums[ i++ ];
}
void ComputeSum( char _num1[], char _num2[], int _sum[] )
{
int num1Counter = strlen( _num1 );
int num2Counter = strlen( _num2 );
int MaxSize = (num1Counter > num2Counter ) ? num1Counter :num2Counter;
bool CarryOver = false;
int tempSum = 0;
int walker = 0;
int s1 = 0;
int s2 = 0;
for ( walker = 0; walker < MaxSize; walker++ )
{
if ( ( num1Counter - 1 ) >= 0 )
s1 = _num1[ num1Counter-- - 1 ] - '0'; //Convert string to int
else
s1 = 0;
if ( ( num2Counter - 1 ) >= 0 )
s2 = _num2[ num2Counter-- - 1 ] - '0'; //Convert string to int
else
s2 = 0;
tempSum = s1 + s2;
if ( CarryOver )
{
_sum[ walker ] = ( ( tempSum % ModFactor ) + 1 ) % ModFactor;
if ( tempSum != 9 )
CarryOver = !CarryOver;
}
else
_sum[ walker ] = ( tempSum % ModFactor );
CarryOver = ( tempSum > 9 ) ? true : CarryOver;
}
if ( CarryOver )
_sum[ walker ] = 1;
}
The input file had the following format:
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX, XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXX, XXXXXXXXXXXXXXXXXXXXXXXXXXXX
where X was any number. The two large numbers are delimited by a comma.
Have fun.