Lab 1: Compile and run

Here is the sequence of steps for the lab assignment:
  1. Login to any computer and start the X Window system by typing startx at the Linux prompt..
  2. Start the netscape browser by typing netscape& (notice the ampersand)
  3. Visit the home page for the class: www.cs.nmsu.edu/~rth/cs/cs177
  4. Click on the link for lab 1. You should then see this page.
  5. Hold down the shift key and click on this link to the source code.
  6. Save the source code as a file, called lab1.cc
  7. Edit lab1.cc to make the comment block contain your name, save the file
  8. Compile the program text by typing: g++ lab1.cc
  9. Run the program by typing a.out to view the output
  10. Run the program with redirected output by typing:
       a.out > lab1.out, where lab1.out is a name of a new file
  11. Use the editor to insert the output file into the program text, at the end of the file.
    Save this file as lab1.submit
  12. Print the source code and output by: lpr lab1.submit
  13. Hand the printed source code and output to me
  14. Go home happy!!