Advertisement
Sabbir-bin

variable memory address

Feb 16th, 2020
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.31 KB | None | 0 0
  1. #include<stdio.h>
  2. int main()
  3. {
  4.   char ch1='A';
  5.   int n1=100;
  6.   //show the charcter memory location
  7.   printf(" value of ch1 = %c\t", ch1);
  8.   printf("Address of ch1 = %p\n",&ch1);
  9.   //show the integer memory location
  10.     printf(" value of n1 = %d\t", n1);
  11.   printf("Address of n1 = %p\n",&n1);
  12.   return 0;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement