Pranitha's clicky turtle reflection

by Pranithavallabhaneni

06 Oct 2022

For this clicky turtle hack my thoughts was to create a different trapeziums by click and to change back ground colors by using arrow keys.

Difficulties: First difficulty I faced was during asssigning colors to the arrow keys. I initially don’t know where to start and later I used myscreen.onkey function and tried multiple times to get it.

myscreen.onkey(pink_trapezium, 'left')
myscreen.onkey(blue_trapezium, 'right')
myscreen.onkey(violet_trapezium, 'up')
myscreen.onkey(red_trapezium, 'down')

Second difficulty was during creating multiple trapeziums by clicking and here the mistake I made was that I gave the clicky function to (x,y) co-ordinates but I forgot to give to trapezium the clicky function and later on I corrected my mistake and did it in the correct way.you can see the code below.

def clicky(x, y):
 trapezium(x,y)

Finally after many attempts I managed to get the code that I required without any errors. I listed my clicky turtle program down below in the link you can have a look in to it. Looking forward to code more…

I'm a first year grad student at School of Information, UT Austin. I'm specializing in Health Informatics. Find Pranithavallabhaneni on Twitter, Github, and on the web.