include stdio include conio int main void int float double printf Ente

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#include<stdio.h>
#include<conio.h>
int main(void)
{
int *a, b;
float *x, y = 3.5;
double *m, n;
a = &b;
printf(" Enter b = ");
scanf("%d", a); /* à-óêàçàòåëü íà ïåðåìåííóþ b */
x = &y; /* x-óêàçûâàåò íà ïåðåìåííóþ ó*/
printf("âûâîä àäðåñîâ âñåõ ïåðåìåííûõ:\n &a=%p &b=%p &x=%p &y=%p &m=%p &n=%p \n", &a, a, &x, x, &m, m);
printf(" a = %p\tb = %d\n", a, b);
system("pause");
b -=(int)y;
printf(" a = %p\t*a = %d\tb = %d\n", a, *a, b);
system("pause");
m =(double*) a; /* m óêàçûâàåò íà b */
printf(" a = %p\tm = %p\n", a, m);
system("pause");
m = &n;
printf(" n = %p\tm = %p\n", &n, m);
system("pause");
n = 5.5;
m+=2; /* óêàçàòåëü m íå óêàçûâàåò íà n */
printf(" n = %lf\t&n = %p\tm = %p\n", n, &n, m);
system("pause");
*m = (double) *a - n + (double) *x;
printf(" m = %p\t*m = %lf\n", m, *m);
system("pause");
m -= 2;
printf(" n = %lf n = %p m = %p *(m+2) = %lf\n", n, &n, m, *(m+2));
system("pause");
printf("x=%p",x);
system("pause");
return 0;
}