5 ms·
Assuming an unsigned int is 32 bits large. Never assume the size of an int; this is what uint8_t, int8_t, uint16_t, int16_t, etc are for. The only thing the sta
by aaronmdjones 9y ago
Assuming an unsigned int is 32 bits large. Never assume the size of an int; this is what uint8_t, int8_t, uint16_t, int16_t, etc are for. The only thing the standards say about the size of an int is that it must be at least as large as a short, which must be at least as large as a char, which must be 1 byte. Even then, 1 byte is not necessarily 8 bits (but it is in POSIX).