We can get the same effect as sleep by playing a sound with blockingPlay. Change the dance code to use a brief sound to pause the dance, rather than sleep.

What will be an ideal response?

```
def danceSound (sound):
makesquare(sound)

def makesquare (sound):
w = makeWorld()
evenlist = []
oddlist = []
for turtles in range (10):
t = makeTurtle(w)
t.turn(turtles*36)
if turtles % 2 == 0:
evenlist = evenlist + [t]
else:
oddlist = oddlist + [t]
for times in range(20):
for sides in range(5):
if times % 2==0:
for t in evenlist:
t.forward(100)
t.turn(90)
else:
for t in oddlist:
t.forward(100)
t.turn(72)
blockingPlay (sound)
```

Computer Science & Information Technology

You might also like to view...

Whenever possible, you should use the manual method and not the Lookup Wizard to setup lookup fields

Indicate whether the statement is true or false

Computer Science & Information Technology

What is the name of the values the method call passes to the method for the parameters?

a. Arguments. b. References. c. Objects. d. Values.

Computer Science & Information Technology