Created
November 20, 2018 19:02
-
-
Save Birch-san/d21f4ae40be9eec598ec3fdd47b0c3c7 to your computer and use it in GitHub Desktop.
Printing 64-bit unsigned integer as hexadecimal
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <inttypes.h> | |
int main(int argc, char** argv) { | |
uint64_t val = (1ULL<<29) -1ULL; | |
printf("0x%" PRIx64 "\n", val); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment