Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package Activity3;
- import kareltherobot.*;
- public class Activity3Main implements Directions {
- public static void main(String[] args) {
- World.readWorld("Lesson1World2.kwld");
- World.setDelay(80);
- World.setVisible();
- UrRobot gary = new UrRobot(5, 1, North, 0);
- gary.turnLeft();
- gary.turnLeft();
- gary.turnLeft();
- gary.move();
- gary.move();
- gary.pickBeeper();
- gary.move();
- gary.pickBeeper();
- gary.move();
- gary.turnLeft();
- gary.move();
- gary.putBeeper();
- gary.move();
- gary.putBeeper();
- gary.turnLeft();
- gary.turnLeft();
- gary.move();
- gary.move();
- gary.turnLeft();
- gary.move();
- gary.pickBeeper();
- gary.move();
- gary.pickBeeper();
- gary.turnLeft();
- gary.turnLeft();
- gary.move();
- gary.move();
- gary.turnLeft();
- gary.move();
- gary.putBeeper();
- gary.move();
- gary.putBeeper();
- gary.turnLeft();
- gary.turnLeft();
- gary.move();
- gary.move();
- gary.turnLeft();
- gary.move();
- gary.move();
- gary.move();
- gary.move();
- gary.turnLeft();
- gary.turnLeft();
- gary.turnLeft();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement