+0  
 
+1
2067
1
avatar+195 

Write a Python program that displays a clock. It should ask the user to input an hour and a minute, and then have the turtle draw a clock face with the hour and minute hands in the correct position.

For example, if the user enters  for the hour and  for the minute, your clock might look like this:



Notice that, since the minute hand is at , the hour hand is three-quarters of the way from  10 to 11.

If the user enters  for the hour and  for the minute, your clock might look like this:



Your clock doesn't have to look exactly like the clock shown above, but your program will be evaluated on whether it precisely draws a clock. The hands should originate from the center of the circle. The 12 and 6 hour tick-mark should be precisely vertically aligned with the center of the circle.

Hint: you might want to use the turtle's  function to draw the twelve tick-marks on the clock.

Please describe the algorithm that you use to draw the clock and to correctly position the hour and minute hands. Also list the inputs you used to test your program.

 May 17, 2018
 #1
avatar+260 
+2

http://www.101computing.net/python-turtle-clock/

 

smileysmileysmiley

 May 17, 2018

2 Online Users