Question
#include int main() { int *ptr, *a; int b, c; int d[10]; b = 10 + 5; c = 10 + 4; ptr = &b;
#include
b = 10 + 5; c = 10 + 4; ptr = &b; a = &b; for (b = 0; b < 10; b += 1) { d[b] = b + 7; }
//*ptr = ____ //*a = ____ //b = ____ //c = ____ //d = ____ ____ ____ ____ ____ ____ ____ ____ ____ ____
b = 4 + 11; c = 6; //*ptr = ____ //*a = ____ //b = ____ //c = ____ //d = ____ ____ ____ ____ ____ ____ ____ ____ ____ ____
for (c = 0; c < 10; c += 2) { printf("%d ",d[c]); d[c + 1] = c / 2 + 10; }
//*ptr = ____ //*a = ____ //b = ____ //c = ____ //d = ____ ____ ____ ____ ____ ____ ____ ____ ____ ____
a = &c; for (c = 0; c < 10; c += 2) { printf("%d ",d[c]); d[c + 1] = c / 2 + 10; if (c % 4 == 0) { printf(" "); } }
//*ptr = ____ //*a = ____ //b = ____ //c = ____ //d = ____ ____ ____ ____ ____ ____ ____ ____ ____ ____
ptr = &d[4]; a = &d[3]; for (*a = 1; *a < 4; *a += 1) { ptr[*a] = *a + 1; printf("%d %d ", *a, ptr[*a]); }
//*ptr = ____ //*a = ____ //b = ____ //c = ____ //d = ____ ____ ____ ____ ____ ____ ____ ____ ____ ____
printf("-- %d -- ", *d + 10); printf("-- %d -- ", ptr[34 % 5] + 10); return(0); }
need all the output from the program as well as all of the variable values at the requested locations. i.e. all the commented sections.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started