1

I have this problem:

convert: 17535455(base 10) to BCD to hexadecimal (another way of saying it: convert the BCD of 17535455(base 10) to Hexadecimal)

should I convert the BCD directly to Hexadecimal? If that would be the case then the answer would also be 17535455(base 16) ?

or could their be another interpretation for this?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
  • what language? do You have arithmetic library? – Jacek Cz Aug 17 '17 at 07:58
  • BCD in hex 'for eyes' is similar to ASCII (string) representation, one hex digit (half of byte) is human readable 'normal' digit – Jacek Cz Aug 17 '17 at 08:00
  • BCD as in Binary-Coded Decimal Form. –  Aug 17 '17 at 08:01
  • BCD is base16. `0x17535455` in your case. So it's a bit unclear as to what *conversion to hexadecimal* implies. – yacc Aug 17 '17 at 08:19
  • or should I do : BCD -> Decimal -> binary -> hexadecimal? –  Aug 17 '17 at 08:48
  • there is no binary / decimal distinction. All numbers are in reality the same. Distinct internal form (yes, BCD i kind of) and externel formatting for human – Jacek Cz Aug 17 '17 at 11:44
  • homework assignment? maybe it meant *convert 17535455(base 10) to BCD _and_ to hexadecimal*... – yacc Aug 18 '17 at 01:51

0 Answers0