Question: Given the following information: The program prompts user to Enter first name or , EOFNAME, to quit, the user enters the name as John

Given the following information: The program prompts user to "Enter first name or ", EOFNAME, " to quit", the user enters the name as John Smith. The hours and rate are entered as: 10 for hours 20 for rate What is the result when the if statement is executed? start Declarations string name num hours num rate num DEDUCTION = 45 string EOFNAME = "ZZZ" num gross num net output "Enter first name or ", EOFNAME, " to quit" input name while name not equal to EOFNAME output "Enter hours worked for ", name input hours output "Enter hourly rate for ", name input rate gross = hours * rate net = gross - DEDUCTION if net > 0 then output "Net pay for ", name, " is ", net else output "Deductions not covered. Net is 0." endif output "Enter next name or ", EOFNAME, " to quit" input name endwhile output "End of job" stop Group of answer choices

A: Net pay for John Smith is 135. B: Net pay for John Smith is 155. C: Net pay for John Smith is 145. D: End of job

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 Databases Questions!