Question: Exercise 2 A Student ADT test application (10 pts) Design an algorithm to test your Student ADT. Your answer should be in the form of

Exercise 2 A Student ADT test application (10 pts) Design an algorithm to test your Student ADT. Your answer should be in the form of pseudo-code, like main(), in which you call all your ADT operations, and check that they worked. Since this is pseudo-code, you obviously cannot run this application, but a careful design of a test-application can make your development work a lot easier, so you should get in the habit of it. Youll implement your Student ADT later, and a well designed test program will help you determine if your ADT implementation is correct. Time spent thinking about it now will save time later. For this algorithm, the pre-and post conditions are trivial, since this is essentially a main program. Feel free to omit them.

Exercise 4 Testing your Student ADT (8 pts) You were asked to design an algorithm to put your Student ADT to the test, by calling each operation at least once in Exercise 2. Convert your pseudo-code from Exercise 2 to Java. To help you, weve provided a guide for the conversion from pseudo-code to Java implementation. Use this as a guide, and not a set of strict instructions. There are too many variations that we cannot account for. 1. Copy your student test design document into a Java file called testStudent.java. Dont change the original! 2. Convert everything in testStudent.java to Java. Work one line at a time, and dont rush. Spend time being sure about syntax. This should take about 30-40 minutes, roughly. 3. You can put your testStudent algorithm in main(). 4. When you think youre done, you can compile it. 5. Correct all the errors! No matter how careful you are, you will always have some. 6. When you have all compiler errors corrected, run your application again. Check the output of your application, and ensure that every operation has the right effect on the Student data.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!