/////////////////////////////////////////////////////////////// // exmp2f.cpp - recursion with functions // // // // Jim Fawcett, ELE591\791, Su'99 // // // // build: cl /GX exmp2f.cpp // /////////////////////////////////////////////////////////////// #include #include #include using namespace std; //----< a recursive function which reorders lines from a file >------ void recurse(istream &in) { string line; getline(in,line); if(in.good()) recurse(in); cout << line << endl; } //----< test >------------------------------------------------------- void main(int argc, char *argv[]) { if(argc == 1) { cout << "\n please enter name of file to process\n\n"; return; } ifstream in; int i; for(i=1; i