<pre> def Straight(x,y): if x > 0: while robot.distance() <= x: correction = (gyro.angle()) * 3 robot.drive(y,correction) if x < 0: while robot.distance() >= x: correction = (gyro.angle()) * 3 robot.drive(-y,correction)
def Phase1(): Straight(1000,500) robot.turn(-360) robot.distance() = 0 Straight(300,500)
robot.distance() = 0
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)