Club Today, Monday 1/13 ROOM: B 100
Computer Science club 1/13 in room B100 (not near library, but near the Guidance office)
Computer Science club 1/13 in room B100 (not near library, but near the Guidance office)
Let’s write a program that solves the map below (which you should create yourself) using only 1 while loop
![]() |
![]() |
![]() |
If you just want to do a single test, use an ‘if’ test, instead of a while loop
…Now we can continue hopping till we get to the end of the map
Your Assignment: Create the map above and complete the program . All that you have to do use is the code at the top and then write the custom method goRoundWater()
- Make the map shown below by adding a flower at (0,23)
- Start a Jeroo at (0,0)
- use a single while loop to get your Jeroo to ( 0, 22)
![]() |
![]() |
![]() |
- Make the map shown below
- Start a Jeroo at (1 , 1 )
- use a single while loop until your Jeroo is at ( 1, 21)
![]()
Objective: Make a jeroo walk around the perimeter of the lank, on the land side. Use a custom method
download the island file
Two Caveats
The classes below represent different ways of representing mathematical concepts like MathExpressions, Fractions etc. and they all implement the Mathable interface.
methods
This class is used to represent Fractions
Instance Variables
Constructor : The constructor should initialize both instance variables
Methods
This is a class that is used to represent mathematical expressions like 3x2or 5x2y2 . It contains the methods and variables described below and it must implement Mathable
Instance Variables
NOTE: you should use the following sytnax
Declare ArrayList’s as type “list”:
Constructor : You can decide how to write the constructor.
methods implement all methods of the Mathable Interface in ways that make sense for this class. The idea with Mathable is that you should be able to tell if the objects are either equivalent, exactly the same and that you should be able to return a String representation (data) that uniquely identifies the given mathematical expression.
variables
and power to the list of powers
. You can not assume that the term does not yet exist in the expression .3x2y5 |
coefficient: 3 variables : [ “x”, “y”] powers : [ 2, 5] |
x1y11 |
coefficient: 1 variables : [ “x”, “y”] powers : [ 1, 11] |
3y2x5 |
coefficient: 3 variables : [ “y”, “x”] powers : [ 5 , 2] |
|
|
April 2nd
String str ="ABCDEFG"
String firstLetter = str.substring(0,1)
String firstTwoLetters = str.substring(0,2)
String lastLttr = str.substring(str.length() -1)
String last_2_lttrs = str.substring(str.length() -2 )
String middle_lttr = str.substring(str.length()/2 , str.length()/2 +1)
Unit 2
Extra credit: Looping over Strings
Unit I
Deadline the day you return from feb break
*Wed/Thursday 21st/22nd
Objective: Your goal is get your jeroo onto the right side of the island. Note that the red areas are nets. You must toss() a flower onto the net before you can go on the net.. You will need the following island file .