Q39
What is the value of x after the following code: x = 5; x += 3; ?
A.
5
B.
8
AnswerC.
3
D.
15
Answer: Option B
Solution
Answer: Option B
Solution:
The += operator adds the right operand to the left operand and assigns the result to the left operand.