Due date: 9/17 @ 8:00pm
The goal of this problem set is to practice writing simple
functions. The functions consume atomic forms of data (numbers, symbols,
images). Some use conditionals to distinguish among different situations.
4.2.1, 4.4.1, 4.4.4, 5.1.2
Formulate the formulas from Problems 2 and 3 on
Set 1 as BSL programs. Then apply the strategy of
HtDP problem 4.2.4 to formulate automatic tests for these two
programs (using check-expect instead of =). Make
sure to turn at least two examples from your table into tests.
Find an image of a spaceship on the web. Then develop a program that
"flies" the spaceship on a 200 x 500 canvas from bottom to top. When the ship's
top end reaches the top margin, make the ship re-appear on the bottom.
Your program should clearly identify at what speed the spaceship moves and a
single change to your program should change the speed of the ship.