Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main(){
- int num=8, x=53, *xp;
- xp = &x;
- num = *xp;
- printf("addr of x is %p \n", &x);
- printf("value of xp is %p\n", xp);
- printf("*xp is %d, x is %d\n", *xp, x);
- *xp = *xp + 1; //same as x = x +1
- printf(" *xp is %d, x is %d\n", *xp, x);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement