188k views
4 votes
We perform the following assignment commands: x:=1; y:=9; z:=x+y; z:=z*y; The result is

User MingalevME
by
4.2k points

1 Answer

5 votes

Answer:

"z" in z=x+y is 10. The first "z" in z=z*y equals 90.

Step-by-step explanation:

Let's start with the first equation, z=x+y. Since we have our given values, all we have to do is add them. If "x" is 1 and "y" is 9, adding 1+9 gives us 10.

Now for the second equation, z=z*y. Since we have both values on the right hand side of the equation, we can already multiply to get our answer. The second "z" in the equation is the answer of "z" in the first equation, which is 10. Since "y" equals 9, multiplying 10 by 9 yields us 90.

Hope this helps buddy!

User Driis
by
3.7k points