312-174

Lab 3

Spring 2000

Due (PreLab, bridge): Friday, 4 Feb 2000, beginning of class.

Due (In-Lab/PostLab): Monday, 7 Feb, beginning of class.

Goals:

  1. Understand dynamic memory ( new and delete ).

  2. Understand const declarations.

  3. Create a robust string ADT.

Requirements.

  1. Complete prelab 3 and the bridge exercise from the Data Structures in C++ lab manual by Roberge. You may work in pairs for the PreLab and bridge.

    Turn in your completed pages 45, 49, and 51 in class on Friday. Place all the files that I need to run your solution into a folder labled with your last name(s) and drag it into the appropriate prelab folder in the Turn-In folder on Nova. If I cannot open your folder, double click on your project file, and run your solution (or at least look at it in C++ builder if you haven't completed it), you will not get credit for handing it in.

  2. You must next complete lab 3 exercise from the lab book. The Lab must be done individually. This part is due by the beginning of class on Monday, 7 February.

  3. Finally, complete postlab exercise 2 . This must be done individually and is due Monday 7 February at the beginning of class.

    Turn in pages 56, 57, and 59 in class monday. Place all of the files that I need to run your in-lab solution into a folder labled with your last name and drag it into the appropriate lab folder in the Turn-In folder on Nova.

Late prelabs, bridges, and postlabs will be penalized as described in the study guide.

All results must be put into the appropriate lab folder on the cs174jb nova account.

All prelabs must have a heading identifying the people who worked on the project. Programs must also contain appropriate comments. See style sheets.

Additional requirements:

  1. Note that your subscript operation must check that the subscript is in bounds. If the subscript is out of bounds, return a ! character.

  2. The comparison operation (==) must compare two strings character by character.

  3. You must use dynamic memory allocation for storing the string. This involves the new and delete operators. (see below).

Hints:

Return to Student Pages

Return to John Barr's Home Page

Last Modified: 4 January 2000

THIS PAGE MAINTAINED BY:
John Barr, Ithaca College