1. Consider the following syntax of a program. int i, j = 26; int *pi, *pj = &j; *pj =…

STUCK with your assignment? When is it due? Hire our professional essay experts who are available online 24/7 for an essay paper written to a high standard at a reasonable price.


Order a Similar Paper Order a Different Paper

1.      Consider the following syntax of a program.

 

    int i, j = 26;

    int *pi, *pj = &j;

    *pj = j + 5;

    i = *pj + 5;

    pi = pj;

    *pi = i + j;

 

Solve the problem by finding and explaining the following:

(1)               &i                   

(2)               &j

(3)               pi

(4)               pj

(5)               *pi

(6)               *pj

(7)               i

(8)               pi

(9)               *(pi-1)

(10)           (*pi+2)

(11)           (pi+2)

(12)            

 

2.      Write a C program using a pointer for keying six integers by the user. The six values are stored in an array using a pointer.  Then print the elements of the array on the screen.  

 

3.      Modify the solution of exercise 2 using a pointer to make the C program to print the elements of the array in reverse order. 

    • Posted: 4 years ago
    • Budget: $20
    Writerbay.net

    Everyone needs a little help with academic work from time to time. Hire the best essay writing professionals working for us today!

    Get a 15% discount for your first order


    Order a Similar Paper Order a Different Paper