+ 1
Why output is 32....?
3 Respuestas
+ 3
You are passing address of 'a' to fun, which has int* b now pointing to that address. So (*b) will print the value 3. Then you are modifying the value at address a by doing *b = 2. If now you print *b in main then it will return 2.
So you have 32 as result.
+ 1
Thankyou so much but last question like *b=&a when we want to change the value in b is it automattically changed in a
+ 1
Vikramjeet Singh yes.