Question: Evaluation: 1 0 points total - 2 points for drawing pseudocode; 4 points for correct output of loopy _ roots function; 2 points for calling

Evaluation: 10 points total -2 points for
drawing pseudocode; 4 points for correct output of
loopy_roots function; 2 points for calling the function in
main; 2 points for attaching the file
-What is this chunk of code doing? Explain each line
in a discussion post with english.
def drawing(a_turtle, side_len):
for i in range(5):
a_turtle.forward(side_len)
a_turtle.right(144)
return None
After, write a function called loopy_roots that takes
no parameters. Using a for loop, print the square
root of every integer between 1 and 10 in this
format: "integer : root". For example:
1:1.0
Call the function in main(). Name the file
sqrt_loop.py and attach it to your discussion post.
Hints: Use math.sqrt (example call:
math.sqrt(2)) to get the square root of each
integer. You will need to import math like we did
with turtle. What variable increases with every
iteration of the loop? You might want to use it.
Evaluation: 1 0 points total - 2 points for

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!