-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f46c4bd
commit 8b3d4b7
Showing
1 changed file
with
14 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#wander.py | ||
|
||
from turtle import * | ||
from random import randint | ||
|
||
speed(0) | ||
|
||
def wander(): | ||
while True: | ||
forward(3) | ||
if xcor() >= 200 or xcor() <= -200 or ycor() <=-200 or ycor()>=200: | ||
left(randint(90,180)) | ||
|
||
wander() |