0
Diffrence of %x and %p
/* in %p there are some extra figures. What are those for?*/ #include <stdio.h> int main() { int var=0; printf(" %p",&var); printf("\n %x",&var); return 0; }
1 Resposta
+ 3
%p is meant for pointer, depending on implementation, it may or may not output the number with hexadecimal notation '0x'. You can also see the hexadecimal notation using %#x format.
https://stackoverflow.com/questions/28716220/why-is-the-format-of-p-and-x-different-in-a-format-string
P.S. Add relevant language in your question tags to improve context clarity 👍