Weekend assignment

Weekend assignment

by Leon Tabak -
Number of replies: 0
  • Please download the program that draws cars. Define a new class that models an object that could be part of a landscape. Imitate the Beetle class. That class models an automobile. You might want to model a tree, a flower, a house, an airplane, or a person. Be creative! At the very least, give your class draw() and move() methods. You might also want to define methods for setting and getting the values of other instance variables. These other variables might control the size and color of your objects, for example.
  • Please download the hexagon program that models percolation. Run an experiment to determine the likelihood of percolation for various values of probability. Probability is the name of the variable that controls the porosity of the rock.
  • Please bring a digital image (or several images) to class on Monday. We will work with an image processing program in the laboratory.

- Leon