Question: Algorithm: Maximum _ of _ Two _ Numbers Start the program. Declare a function called findMaximum, which takes two parameters ( num 1 and num
Algorithm: MaximumofTwoNumbers
Start the program.
Declare a function called findMaximum, which takes two parameters num and num and returns the result value.
Declare two variables, num and num to store the two input numbers.
Read the values of num and num from the user.
Call the findMaximum function and pass the values of num and num as arguments and store the returned value in a variable called maximum.
Print the value of maximum as the result.
End the program.
function findMaximumnum num:
Compare the values of num and num
If num is greater than num return num
Otherwise, return num
End of function
What is the result of "Maximumof TwoNumbers"'algorithm if num and num are equal?
Pick ONE option
The program terminates with an error.
The program prints "Both numbers are equal."
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
