1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | #include<stdio.h>
void main()
{
int a, *b;
b = &a;
printf("Enter the value of A:- ");
scanf("%d",b);
printf("\n(Indirect) Address of A = %u.\n", b);
printf("(Direct) Address of A = %u.\n", &a);
printf("(Pointer) Value of A = %d.\n", *b);
printf("(Direct) Value of A = %d.\n", a);
printf("(address operator) Value of A = %u.\n", *(&a));
printf("Address of B = %u.\n", &b);
printf("Value of B = %u.\n", b);
printf("Value of B = %u.\n", *(&b));
}
|
Run the Program and check the code.
0 comments:
Post a Comment