type in cmd window
program.exe < file.in program will read file.in as stdin program.exe > file.out as above, but stdout program.exe < file.in > file.out, and here you have what you need—strach