What does the phrase “garbage in, garbage out” mean? Refer to the section of you
ID: 3818016 • Letter: W
Question
What does the phrase “garbage in, garbage out” mean? Refer to the section of your textbook defining an input validation loop in chapter 7. Using the 7.2 Input Validation Loop example, modify the following pseudocode validation loop to check for negative wholesale cost as well as a maximum wholesale cost not to exceed $50.00.
28 // Validate the wholesale cost.
29 While wholesale < 0
30 Display "The cost cannot be negative. Please"
31 Display "enter the correct wholesale cost."
32 Input wholesale
33 End While
Explanation / Answer
while True
display "enter whole sale cost"
input wholesale
if wholesale <0
Display "The cost cannot be negative. Please"
if wholesale > 50
Display "enter the correct wholesale cost."
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.