hex package:formatting

Render an integer using hexadecimal notation. (No leading 0x is added.) Has a specialized implementation.
Render an integer using hexadecimal notation. (No leading "0x" is added.)
Render an integral type in hexadecimal.
Render an integer using octal notation with a leading 0x, padding with zeroes to the given width:
>>> format (hexPrefix 16) 4097
"0x0000000000001001"
Printing integrals in hex (base-16).
Render an integer using hexadecimal notation with a leading 0x. See also hexPrefix for fixed-width formatting.