Last active
December 10, 2020 08:12
-
-
Save hotcoffeehero/1d1f59323cfd204597c31e34c90254e8 to your computer and use it in GitHub Desktop.
Reeborg's World Hurdle Four
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def turn_right(): | |
turn_left() | |
turn_left() | |
turn_left() | |
def round_corner(): | |
turn_right() | |
move() | |
turn_right() | |
def jump(): | |
turn_left() | |
while wall_on_right(): | |
move() | |
round_corner() | |
while front_is_clear(): | |
move() | |
turn_left() | |
while not at_goal(): | |
if wall_in_front(): | |
jump() | |
else: | |
move() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment