Monday (lecture + lab: actual programming) 

Tuesday review of everything and so on 

Wednesday Exam (Chapters 1-9 in the book) 
   Could be used as a Midterm Makeup
or A Mock-Up Final Exam (mutually exclusive)

Thursday  Final Exam (lecture + lab)

import javax.swing.*; 
import java.awt.*;
import java.util.*; 

class Point {
  int x, y;
  Point(int x, int y) {
    this.x = x;
    this.y = y;
  }
}

abstract class Shape {
  Point location; 
  Shape(Point where) {
    this.location = where; 
  } 
  abstract void draw(Graphics g); 
}

class Circle extends Shape {
  int radius;
  Circle(Point center, int radius) {
    super(center); 
    this.radius = radius;
  } 
  void draw(Graphics g) {
    g.setColor(Color.YELLOW); 
    g.fillOval(location.x - radius, location.y - radius, 2 * radius, 2 * radius);
    g.setColor(Color.BLUE); 
    g.drawOval(location.x - radius, location.y - radius, 2 * radius, 2 * radius);
     
  }   
}

class One extends JFrame {
  One(int howMany) {
    Two screen = new Two(howMany); 
    this.add( screen ); 
    this.setSize(400, 400); 
    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    this.setVisible(true); 
  } 
  public static void main(String[] args) {
    int howMany = Integer.parseInt(args[0]); 
    One a = new One(howMany); 
   
  } 
}

class Two extends JComponent {
  Two(int size) {
    this.circles = new ArrayList<Shape>(); 
    for (int i = 0; i < size; i++)
      circles.add(new Circle(new Point((int) (Math.random()* 300) + 50, 
                                       (int) (Math.random()* 300) + 50), 
                                       (int) (Math.random()* 40) + 10)); 
  } 
  int i; 
  ArrayList<Shape> circles;; 
  public void paintComponent(Graphics g) {
    this.i += 1; 
    System.out.println( " Howdy. " + i ); 
    for (Shape c : this.circles) 
      c.draw(g); 
  }  
}

From this we made a change:

import javax.swing.*; 
import java.awt.*;
import java.util.*; 
import java.awt.event.*;

class Point {
  int x, y;
  Point(int x, int y) {
    this.x = x;
    this.y = y;
  }
}

abstract class Shape {
  Point location; 
  Shape(Point where) {
    this.location = where; 
  } 
  abstract void draw(Graphics g); 
  void moveTo(int x, int y) {
    this.location = new Point(x, y); 
  }
}

class Circle extends Shape {
  int radius;
  Circle(Point center, int radius) {
    super(center); 
    this.radius = radius;
  } 
  void draw(Graphics g) {
    g.setColor(Color.YELLOW); 
    g.fillOval(location.x - radius, location.y - radius, 2 * radius, 2 * radius);
    g.setColor(Color.BLUE); 
    g.drawOval(location.x - radius, location.y - radius, 2 * radius, 2 * radius);
  }   

}

class One extends JFrame {
  One(int howMany) {
    Two screen = new Two(howMany); 
    this.add( screen ); 
    this.setSize(400, 400); 
    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    this.setVisible(true); 
  } 
  public static void main(String[] args) {
    int howMany = Integer.parseInt(args[0]); 
    One a = new One(howMany); 
   
  } 
}

class Two extends JComponent implements MouseMotionListener, MouseListener {

  public void mouseEntered (MouseEvent e) { } 
  public void mouseExited  (MouseEvent e) { } 
  public void mousePressed (MouseEvent e) { } 
  public void mouseReleased(MouseEvent e) { } 
  public void mouseClicked (MouseEvent e) { } 

  Shape current; 
  public void mouseMoved(MouseEvent e) {
    System.out.println("Mouse moved at (" + e.getX() + ", " + e.getY() + ")"); 
  } 
  public void mouseDragged(MouseEvent e) {
    System.out.println("Mouse dragged at (" + e.getX() + ", " + e.getY() + ")"); 
    int x = e.getX(), y = e.getY(); 
    this.current.moveTo(x, y); 
    this.repaint(); 
  }     
  Two(int size) {
    this.addMouseMotionListener(this); 
    this.circles = new ArrayList<Shape>(); 
    for (int i = 0; i < size; i++)
      circles.add(new Circle(new Point((int) (Math.random()* 300) + 50, 
                                       (int) (Math.random()* 300) + 50), 
                                       (int) (Math.random()* 40) + 10)); 
    this.current = this.circles.get(0);
  } 
  int i; 
  ArrayList<Shape> circles;; 
  public void paintComponent(Graphics g) {
    this.i += 1; 
    System.out.println( " Howdy. " + i ); 
    for (Shape c : this.circles) 
      c.draw(g); 
  }  
}

This was not all there was, but the rest is in the lab notes. 

--