Question: C programming. outputting hexadecimal. Hello. after I run my program, I need the console to show 0000000 00 05 after I run: $ od -t
C programming. outputting hexadecimal.
Hello. after I run my program, I need the console to show 0000000 00 05 after I run: $ od -t x1 mydisplayfile command.
I am just trying to show the value 5 using 2 bytes. I have been trying to do: unsigned int nn = 5; printf("%04x",nn); but I get:
after I run my program, I need the console to show 0000000 00 05 after I run: $ od -t x1 mydisplayfile command.
I am just trying to show the value 5 using 2 bytes. I have been trying to do: unsigned int nn = 5; printf("%04x",nn); but I get: 0000000 30 30 30 35 0000004
in the console. please help me.
when i open the actual file it shows :
0005
which is what i need. but I need that to be shown in the console when i use that speicifc command. thank you.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
