Hello,
I’m new to this forum and fairly new to programming.
I have a hexadecimal number that I wish to put into a buffer so I can display the 2 least significant bits, that is the two last digits. i.e the number look like this unsigned short = 0xFE18 but I’d like to display on the screen just “18”. Which is the best way to do this?
Thanks you so very much!
/Pamela
|
~ Б0ЯИ Τ0 С0δЭ ~
|
![]() |
| 6Jul2009,23:16 | #2 |
|
Welcome to G4EF, Pamela
![]() Don't know, if this is the best, bu you can do it this way: (1) Print the hex number to a string: Code: C
Code: C
Complete test program: Code: C
|
|
Newbie Member
|
|
| 7Jul2009,00:03 | #3 |
|
Thank you so much!
![]() /pamela |
|
~ Б0ЯИ Τ0 С0δЭ ~
|
![]() |
| 7Jul2009,05:34 | #4 |
|
My pleasure
|
|
Security Expert
|
|
| 7Jul2009,05:47 | #5 |
|
pamela
put this smiley in yahoo IM to see what it is " :X :-*"
|



