Ask your own question, for FREE!
Computer Science 23 Online
OpenStudy (anonymous):

Suppose that alpha and beta are int variables. The statement alpha = beta--; is equivalent to the statement(s) ____. a. alpha = 1 - beta; b. alpha = beta - 1; c. beta = beta - 1; alpha = beta; d. alpha = beta; beta = beta - 1

OpenStudy (anonymous):

d. The unary postfix decrement operator, when used in an expression, decrements the value of its operand but has the old value of the operand.

OpenStudy (anonymous):

alpha = beta--; is the same as aplha = beta-1; so it is A

OpenStudy (anonymous):

It's D because : alpha will take the value beta then beta will be decremented

OpenStudy (rsmith6559):

The prefix operators increment/decrement then evaluate. The postfix operators evaluate then increment/decrement. D is correct.

OpenStudy (anonymous):

Thank You!

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!