Printf(“\n The address of k=%u”, &k);
Printf(“\n The value of k=%d”, k);
The address of k=2020
The value of k=10
• Here the expression ‘&k’ gives the address of ‘k’ in which it is stored, the format string %u or %p is used to print address.
• Here the expression ‘&k’ is pronounced as “address of k”, the space for ‘k’ at run time may be allocated anywhere in the RAM, and to get the address of ‘k’, reference operator is used.
• The address of a variable may not be a fixed location like 2020 above, and is randomly given by the computer.