MIPI_AdvancedC_FRTK/Lect2/37.c

12 lines
282 B
C
Raw Normal View History

2024-11-14 08:45:50 +03:00
#include <stdio.h>
int main(void)
{
int num = 2147483647;// 0x7fffffff
int *pi = &num;
short *ps = (short*)pi;
printf("pi: %p Value(16): %x Value(10): %d\n", pi, *pi, *pi);
printf("ps: %p Value(16): %hx Value(10): %hd\n", ps, *ps, *ps);
return 0;
}