Names specified here
Name Description Notes Source Availability
INT32_MAX Maximum value of int32_t L ? M <stdint.h> C99 C11
INT32_MIN Minimum value of int32_t L ? M <stdint.h> C99 C11
int32_t Signed integer type of exactly 32 bits L ? T <stdint.h> C99 C11
PRId32 Decimal output conversion specifier for int32_t ? M <inttypes.h> C99 C11
PRIi32 Decimal output conversion specifier for int32_t ? M <inttypes.h> C99 C11
PRIo32 Octal output conversion specifier for uint32_t ? M <inttypes.h> C99 C11
PRIu32 Decimal output conversion specifier for uint32_t ? M <inttypes.h> C99 C11
PRIX32 Hexdecimal output conversion specifier for uint32_t ? M <inttypes.h> C99 C11
PRIx32 Hexdecimal output conversion specifier for uint32_t ? M <inttypes.h> C99 C11
SCNd32 Decimal input conversion specifier for int32_t ? M <inttypes.h> C99 C11
SCNi32 General input conversion specifier for int32_t ? M <inttypes.h> C99 C11
SCNo32 Octal input conversion specifier for uint32_t ? M <inttypes.h> C99 C11
SCNu32 Decimal input conversion specifier for uint32_t ? M <inttypes.h> C99 C11
SCNx32 Hexdecimal input conversion specifier for uint32_t ? M <inttypes.h> C99 C11
UINT32_MAX Maximum value of uint32_t L ? M <stdint.h> C99 C11
uint32_t Unsigned integer type of exactly 32 bits L ? T <stdint.h> C99 C11

uint32_t and int32_t are optional integer types of exactly 32 bits. Both types have no padding, and int32_t uses 2's complement. uint32_t is unsigned, and has the range zero to UINT32_MAX, which is [0, +4294967295]. int32_t is signed, and has the range INT32_MIN to INT32_MAX, which is [−2147483648, +2147483647].

The following macros can be used in the fmt argument of printf to print arguments of types uint32_t and int32_t:

The following macros can be used in the fmt argument of scanf to scan arguments of types uint32_t * and int32_t *:

The existence of macros such as PRIu32 can be used to detect the existence of uint32_t with conditional compilation.

Related types:

Property uint32_t int32_t
Width (bits) 32
Lowest value 0 −2147483648
Highest value +4294967295 +2147483647
printf base 10 "%" PRIu32 "%" PRId32 or "%" PRIi32
base 8 "%" PRIo32
upper-case base 16 "%" PRIX32
lower-case base 16 "%" PRIx32
scanf base 10 "%" SCNu32 "%" SCNd32
base 8 "%" SCNo32
base 16 "%" SCNx32
base 16, 8 or 10 by prefix "%" SCNi32

CHaR
Sitemap Supported
Site format updated 2024-06-05T22:37:07.391+0000
Data updated 1970-01-01T00:00:00.000+0000
Page updated 2022-06-17T21:43:05.000+0000