answersLogoWhite

0

One way to accomplish this is to allow the printf statement to do the work for you.

Example:

printf("Decimal %d = hex %02x\n", number, number);

Or you could use the windows calculator. Select the Dec radian, type your number in, then select Hex radian.

User Avatar

Wiki User

14y ago

Still curious? Ask our experts.

Chat with our AI personalities

ReneRene
Change my mind. I dare you.
Chat with Rene
BeauBeau
You're doing better than you think!
Chat with Beau
MaxineMaxine
I respect you enough to keep it real.
Chat with Maxine

Add your answer:

Earn +20 pts
Q: Write a program to convert decimal numberto hexadecimal number?
Write your answer...
Submit
Still have questions?
magnify glass
imp