This is my program:
#include <iostream.h>
#include <fstream.h>
int main ()
{
ifstream fin ("whatever.txt");
char x[6];
fin >> x;
cout << x;
return 0;
}
All that this does is get one character from the file, but I want to read in an entire string, of length 1 to 6. How?
Thanks for any help