In C poti sa faci ceva de genu
#include <cstdio>
using namespace std;
int main()
{char *s;
FILE *fin=fopen( "file.txt", "rt" );
fseek( fin, 0, SEEK_END ); //go to the end of the file;
unsigned int size=ftell( fin ) //get the file size in bytes
s=new char[ sizeof(char)*size+1];
rewind( fin ); //go back to beginning
fread( s, sizeof(char), size, fin ); //copy from buffer fin to s the content
.....
return 0;
}