// Chris Welty

#include <fstream.h>
#include <iostream.h>

int main()
{
  ifstream in;
  ofstream out;
  char i;

  in.open("test1");
  out.open("test2");
  
  // read-from-file cliche
  in >> i;  // prime the stream

// check for EOF after every read
  while(in) {
    cout << i << endl;
    out << i << endl;
    in >> i; 
  }
}

