Jeroo Lab 3 (Basic) - Using methods
Rewrite your old program so it uses methods. You must use the method names that are specified. | |||
![]() |
3a. Open the Island File named IslandN.jev Write a program to get a Jeroo from the beginning (0,0) into the house of nets at the end The jeroo must pick up the flower on the path, toss it into a net to get through the barrier and then go into the house. Divide the program up into 3 original jeroo methods:
|
||
On your own - do all 4 | |||
![]() |
3b. A jeroo starts out on Skinny Island on the western shore, without any flowers, and must find a way across to the eastern shore by picking the flowers and using them to break through the nets. Create a method called disableNet to pick one flower and toss it at the net ahead.. Fill out the tag sheet when you finish. |
||
3c. Create a Jeroo anywhere on NotInARow Island It's mission is to rearrange the flowers by picking and planting so they are all in a row. Solve the problem as efficiently as possible by using a well-constructed method. Save as InARow |
|
||
3d. Create 4 Jeroos, one in each corner of RelayRaceIsland as pictured to the left. Each Jeroo starts out holding a single flower. The first Jeroo is standing on top of a flower which it picks immediately and then races forward to the next Jeroo (disabling the net along the way, of course) and passes the flower on. The second Jeroo passes the flower to the third, and the third to the fourth. There should be one well-written method that all 4 Jeroos can use to complete the race. |
|||
Speller is a clever Jeroo who can write words with flowers. Copy the SpellingBee program to your disk and watch how well Speller can write B's, I's and L's.
Notice these features of the SpellingBee program:
Speller is tired of having such a limited vocabulary. Create a new method to draw the most common letter, E, and have Speller write out the word "BELLE" TOP GRADE: Add one new letter method to the program and have Speller spell out 2 different (polite) words on the island. |
|||
TOP GRADE: | |||
TG1. Create an empty island where a jeroo plants the letters OOP (Object Oriented Programming) written twice in flowers, one directly below the other. Use methods as efficiently as possible. This means that there should be almost NO repeated lines of code. Call the program OOPMethods. |
|
||
TG2. Use the disableNet method from your skinnyIsland lab 3b. to instruct a Jeroo to pick a flower and toss it at the net ahead. Use one other original method to create the most efficient solution to get Wendy across stripeIsland starting at 12,0 and ending at the eastern shore. Study the layout of the island before you start to write your code to see if you can discover a pattern that will allow you to re-use the same methods over and over again to solve the problem. Call the program crossStripes. |
![]() |
||
TG3. Design a symetrical island with obstacles and a jeroo in each corner, create methods to send all the jeroos to the middle and then back to the corners again in a dance that utilizes all 6 of the jeroo action methods. Call the program yourNameOriginalDance. |