Lab project (cont'd)

Display Figure 4.

Your world will display the distance from the coach to the chicken as shown in Figure 4.

(It is not necessary to match the value of the distance shown in Figure 4)

Then the chicken will turn to the right, making two complete revolutions around its own green axis.

Movie of the lab project.

Listing 3. Updated main method for Alice135LabProjA.a2w.
  public void main ( ) {
    
       // Copyright 2007 R.G.Baldwin
  // Program demonstrates defining two new functions.
  doInOrder {
       print( ( Distance to chicken is: + ( ( coach.getDistanceToChicken ( ) ) .toString() ) ) );
  ( coach.getChicken ( ) ) .turn( RIGHT , 2 revolutions );
  }
  }