COMPUTER SCIENCE Summer 2006
Unit 1, Lab06 A Half Dozen Tasks

  1. Load Lab06.html. You need to write the code for these six tasks:
          public static void task_01()
          { //go to the end of the row of beepers
             Robot temp = new Robot(1, 1, World.EAST, 0);
          
          }
          
          public static void task_02()
          { //go to the beeper
             Robot temp = new Robot(1, 2, World.EAST, 0);
    	 
          }
          
          public static void task_03()
          { //go to the wall
             Robot temp = new Robot(1, 3, World.EAST, 0);
          
          }
           
          public static void task_04()
          { //go to the wall, pick up all the beepers (max one per pile)
             Robot temp = new Robot(1, 4, World.EAST, 0);
          
          }
           
          public static void task_05()
          { //go to the wall, pick up all the beepers
             Robot temp = new Robot(1, 5, World.EAST, 0);
          
          }
           
          public static void task_06()
          { //go to the end of the row of beepers, there is one gap
             Robot temp = new Robot(1, 6, World.EAST, 0);
          
          }
    
    

      Use loops such as:
         
         while (temp.nextToABeeper()) {
            temp.move();
         }