Question: 7 . 1 1 LAB: Calling Functions In Loops Problem: Construct a program that makes us of a function inside of a loop to count
LAB: Calling Functions In Loops
Problem:
Construct a program that makes us of a function inside of a loop to count down from some positive integer value until the value equals Create a user function that you create that takes an integer as an argument, verifies that the value is valid and prints messages and returns values based on that value. If the value is larger than print the value and a newline to standard output, then return a to the calling function, indicating it is a good value and to keep going. If the value passed to the function is print the value and the message "Blast Off" then return a value to the calling function of and if it is less than return a to the calling function.
In the main function, create a loop that is controlled by a user provided integer input value and calls the function you created and uses the return value to either quit or decrement the value and continue calling the function in the loop.
Objective:
Demonstrate declaring a User Defined Function.
Demonstrate Pass By Value.
Demonstrate Calling Functions in loops.
Example output
qxzqy
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
