COP 3014 Recitation - Week 5

Reading from files

  1. We'll go over file input together first, then you can continue
  2. Write a program that will read 5 numbers from a file and then calculate the average. You may use this as a guide. NOTE that you will need to put your input file in the same directory as your ".cpp" file is.

Pass by value and pass by reference

  1. We'll go over this together
  2. And this

Pointers, again

  1. We'll go over this together
  2. Complete this program
  3. Let's go over this together
  4. And this
  5. And this
  6. And this
  7. And this
  8. And this
Program examples