8. Here is program using the pseudocode presented in lectures: total 0 operation add D 1 get number o while number o if ope 8. Here is program using the pseudocode presented in lectures: total 0 operation “add” D 1 get number o while number o if operation = “subtract” then total total – 1 operation “add” else r total total +1 operation “subtract” LIFL end if number number 1 end while print total Using this program which of the following give the correct output with the given input? X. Input: 0, Output: 0 Y. Input: 7, Output: 0 Z. Input: 9, Output: 0



Source link

Leave a Reply

Your email address will not be published. Required fields are marked *