noob question! How can i read 'a whole ifstream' into a stdlib 'string'? The current way i'm using for all my projects right now wastes much time i think:
string code;
ifstream input("~/myfile");
char c1=input.get();
while (c1!=EOF)
{
    code+=c1;
    len++;
    c1=input.get();
}
BTW i prefer to do line and whitespace management myself.
 
     
    