Consider Following Piece Pseudocode Ischeap X Issoldout X Print Buy Else Print T Buy Suppo Q37258953

Consider the following piece of pseudocode: if (isCheap (x) and not (isSoldout (x))) then print(Buy it!) else print(Cant

Question about the condition

Consider the following piece of pseudocode: if (isCheap (x) and not (isSoldout (x))) then print(“Buy it!”) else print(“Can’t buy!”) Suppose we rewrite it as: if (condition) then print(“Can’t buy!”) else print(“Buy it!”) What should condition be, so that the rewritten code is equivalent to the original? Select one: a. not (isCheap (x)) and isSoldout (x) b. not( isCheap (x) or not (issoldout (x)) c. not (isCheap (x)) or isSoldout (x) d. not ( isCheap (x) and

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.