Name: __________________________________________
Objective: Polymorphism
Quiz
Trace the following code
Student s = new Student("Archie");
Student t = new Student("Reggie");
Student p = t;
p.setName("Jughead");
p = s;
System.out.print(p.getName());
Instructions
- Open your Solar System project
- Down load the files from Lab 19 Solar System VII. You will be downloading a new applet file.
- Modify the applet as follows:
- Create a Rocky and Gaseous planet.
- Create a Shuttle and GPS object.. Start their animation.
- If the user clicks on a spacecraft, make it the current one
- If the user clicks on the background, move the current spacecraft to the to the clicked location.
Wrap-up
- Print the PDF version of these instuctions and hand in
Grading
| Requirement |
Points |
Out of |
Note |
| Quiz |
|
1 |
|
| Click behavior |
|
7 |
|
| Total |
|
8 |
|
Notes
Comments (0)
You don't have permission to comment on this page.