Sequence of Square Roots Write a program that prints the square root values of the first 30 even integers, starting at 1. Use a while statement to achieve this output. Your output should have one value per line. The name of your loop control variable should be value. The loop should increment the value variable by one each iteration through the loop. The use of an if statement is required for this solution. You may assume that the math library (module) has previously been imported for you. 14 15 16 17 18 19 Check My Solution Test Results: ✓ Your program uses the while statement. Your program does not correctly test the required loop control variable (value). Your program correctly increments the required loop control variable (value). Your program correctly computes the value's square root. Your program prints output. Your program uses an if statement to check for even values. 3 tests were not run. X ✓ ✓ print(math.sqrt(value)) # Increment the count of even numbers processed even_count += 1 # Increment the value to check the next integer value += 1 ✓ X 56% of tests passed. Reset
Types of Loop
Loops are the elements of programming in which a part of code is repeated a particular number of times. Loop executes the series of statements many times till the conditional statement becomes false.
Loops
Any task which is repeated more than one time is called a loop. Basically, loops can be divided into three types as while, do-while and for loop. There are so many programming languages like C, C++, JAVA, PYTHON, and many more where looping statements can be used for repetitive execution.
While Loop
Loop is a feature in the programming language. It helps us to execute a set of instructions regularly. The block of code executes until some conditions provided within that Loop are true.
write python code to solve it thank you!
Step by step
Solved in 3 steps with 2 images