In the above code when run it will print the text to a file but will only read one word how would I have it read the whole line.Code:#include <iostream> #include <fstream> using namespace std; typedef string str; void main() { char wrd[50]; ofstream fout("shorttext.txt"); fout << "Hello World"; fout.close(); ifstream fin("shorttext.txt"); fin >> wrd; cout << wrd; fin.close(); }