For this question, I needed to determine the final values of all
p, q, w, and x after the following program runs. I have already
figured out the answers by using a cout statement but I need
help understanding how to actually get the numbers that are output.
Please explain how to trace what is going on so I know how to
determine the answer without using a cout statement.
void main()
{
int p, q, *r, *s;
float w, x, *y, *z;
r = &q;
*r = 13;
p = q;
s = r;
r = &p;
y = &w;
z = &x;
*s += 1;
*y = *s;
*z = *y;
}
For this question, I needed to determine the final values of all p, q, w, and x after the following program runs. I have
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
For this question, I needed to determine the final values of all p, q, w, and x after the following program runs. I have
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!