← back to the schedule


Mystery Functions MINI-LAB


Getting Started

In this lab you will be reading a file called FourMystFunctions.java that actually contains 5 mystery functions:

mystery1
mystery2
mystery3
mystery4
mystHelper

Open FourMystFunctions.java or download it to your machine to read it there. One advantage of having your own copy is that, if you want to, you can edit the comments as you go to help you figure out what each function is doing.

Think/Pair/Share Exercise:

Start with mystHelper — what is the function doing? What is its probable purpose? [By the way, 2 of the 4 mystery functions use this helper function.]

Small Group Reading Exercise:

Divide into small groups. Different groups should start with different mystery functions (1, 2, or 3). When you have one figured out, move on to the next number mod 3. In other wods, from mystery1 go on to mystery2; from mystery2 go on to mystery3; from mystery3 go on to mystery1.

You can go on to mystery4 when you have worked through the other 3.

Larger Group or Class Discussion:

What is going on with mystery4?

Follow-up Work:

Do the follow-up work described in this document.


← back to the schedule