InterviewSolution
Saved Bookmarks
| 1. |
Write a function RevText() to read a text file “ Input.txt “ and Print only word starting with ‘I’ in reverse order . Example: If value in text file is: INDIA IS MY COUNTRY Output will be: AIDNI SI MY COUNTRY |
|
Answer» vText() { ifstream in ("Input.txt"); CHAR word[25]; while(in) { in>>word; if (word[0]=='I') COUT< |
|