CIS 700 Assignment 1: Pig
Summer II 2010, David Matuszek

Purpose of this assignment:

To get you somewhat familiar with Scala.

The assignment:

I have provided a simple game program, Pig.scala.

  1. Install your Scala environment (see the wiki for details).
  2. Compile and run the program. Play the game a few times, so that you know what it does. Instructions are included in the program.
  3. Look at the documentation for the program.
  4. Translate the program into Java, keeping it as much like the Scala program as possible. That is, use the same classes, methods, logic, and comments, as well as the same behavior. (Excluding comments, the program is less than 100 lines of Scala, so this shouldn't be difficult.) Don't forget to translate the javadoc comments from wiki markup to HTML markup.


Due date:

Zip your complete program (source, binaries, javadoc files) before midnight, Sunday July 11, and submit it via Blackboard.

Common errors: