c_primer_plus/chapter3/altnames.c
2021-10-16 19:11:48 +08:00

15 lines
343 B
C

#include <stdio.h>
#include <inttypes.h>
int main(int argc, char const *argv[])
{
int32_t me32;
me32 = 45933945;
printf("First, assume int32_t is int:");
printf("me32 = %d\n", me32);
printf("Next, let't not mak any assumption.\n");
printf("Instead, use a \"macro\" from inttype.h:");
printf("me32 = %" PRId32 "\n", me32);
return 0;
}