Question: Disclaimer if coding is needed: THIS IS A PSEUDO CODE CLASS 1 . The programmer intends for this pseudocode to display three random numbers in
Disclaimer if coding is needed: THIS IS A PSEUDO CODE CLASS The programmer intends for this pseudocode to display three random numbers in the range of through According to the way we've been generating random numbers in this book, however, there appears to be an error. Can you find it
This program displays three random numbers
in the range of through
Declare Integer count
Display three random numbers.
For count To
Display random
End For
Can you find the reason that the following pseudocode function does not return the value indicated in the comments?
The calcDiscountPrice function accepts an item's price and
the discount percentage as arguments. It uses those
values to calculate and return the discounted price.
Function Real calcDiscountPriceReal price, Real percentage
Calculate the discount.
Declare Real discount price percentage
Subtract the discount from the price.
Declare Real discountPrice price discount
Return the discount price.
Return discount
End Function Can you find the reason that the following pseudocode does not perform as indicated in the comments?
Find the error in the following pseudocode.
Module main
Declare Real value, result
Get a value from the user.
Display "Enter a value."
Input value
Get percent of the value.
Call tenPercentvalue
Display percent of the value.
Display percent of value, is result
End Module
The tenPercent function returns percent
of the argument passed to the function.
Function Real tenPercentReal num
Return num
End Function
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
