jbrad1322 jbrad1322
  • 04-07-2019
  • Computers and Technology
contestada

What is the value of x after the following statements execute? int x, y, z; y 12; z 3; X= (y*(z+y-10); A. 36 B. 144 C.60 D. None of these

Respuesta :

PhantomWisdom PhantomWisdom
  • 12-07-2019

Answer:

60

Explanation:

According to the operator precedence, the bracket comes in the top. So, the program solve expression in the bracket first.

In the code, the value of Y is 12  and z is 3

substitute the value in the formula.

X = (12*(3 + 12 - 10)).

So, the program calculate the value (3 + 12 - 10) first which gives 5.

After that program evaluate (12 * 5) which gives 60.

Therefore, the answer is 60.

Answer Link

Otras preguntas

how is mass transit in cities a possible solution tk urban air pollution?
Marika and Freddy sold 70 homes for Ron Realty. If Marika sold 2.5 times as many homes as Freddy, how many homes did each sell?
Prove that (x^5)-(x^2)+2x +3=0 has at least one real root. Prove that x=cosx has at least one solution.
How were life forms affected by the rise in atmospheric oxygen levels that began 2.2 billion years ago?
find an equivalent expression without parentheses -(50x-15y+15)=
Scarcity is the condition of not having enough goods and services to satisfy everyone's?
Can someone use the word delta in a sentence
Marika and Freddy sold 70 homes for Ron Realty. If Marika sold 2.5 times as many homes as Freddy, how many homes did each sell?
what is the answer for (20,8),(9,16) ?
How is it possible for Mercury to have frozen ice ?