stairsweeper
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
stairsweeper [2019/08/23 09:43] – [StairSweeperRunner.java] frchris | stairsweeper [2023/08/22 09:50] (current) – frchris | ||
---|---|---|---|
Line 3: | Line 3: | ||
<code java> | <code java> | ||
import kareltherobot.Robot; | import kareltherobot.Robot; | ||
+ | |||
+ | /** | ||
+ | * Classwork | ||
+ | * @author (your name) | ||
+ | * @version (a version number or a date) | ||
+ | */ | ||
public class StairSweeper extends Robot | public class StairSweeper extends Robot | ||
Line 16: | Line 22: | ||
public void climbStair() | public void climbStair() | ||
{ | { | ||
- | turnLeft(); | + | // code needed here |
- | move(); | + | |
- | turnRight(); | + | |
- | move(); | + | |
} | } | ||
private void turnRight() | private void turnRight() | ||
{ | { | ||
- | turnLeft(); | + | //coded needed here |
- | turnLeft(); | + | |
- | this.turnLeft(); | + | |
} | } | ||
Line 66: | Line 67: | ||
alexa.climbStair(); | alexa.climbStair(); | ||
alexa.pickBeeper(); | alexa.pickBeeper(); | ||
- | alexa.climbStair(); | + | alexa.turnOff(); |
- | alexa.pickBeeper(); | + | |
- | alexa.climbStair(); | + | |
- | alexa.pickBeeper(); | + | |
- | alexa.turnLeft(); | + | |
} | } |
stairsweeper.1566567812.txt.gz · Last modified: 2019/08/23 09:43 by frchris