Homework 1 - Structures and Pointers

Due: Wednesday, April 6, 2011 at 5:00pm

Coding Conventions

The following coding conventions should be used for all assignments.

Assignment

The purpose of this assignment is to create a structure called StudentRecord to track and calculate student grades in a fictitious course. You will also be using a pointer to dynamically allocate and delete a StudentRecord object. Any assignment that does not use new/delete will have points deducted.

The StudentRecord structure must have the following pieces of data:

You will have the following two function to manipulate StudentRecord objects. You may add additional functions if you wish, but you must have these two functions to get full points: Your main function will have the following loop:
do
  call createStudent and store the returned address in a StudentRecord pointer
  if the pointer is NULL
    print an error message
    break out of the loop
  end-if
  call printStudent with the StudentRecord pointer
  deallocate the StudentRecord pointer
  prompt the user "Do you wish to continue?"
  read in their response
  convert the response to all lowercase letters
while the user responds "yes" or "y"
Email your source code to me by the due date.