Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a lot of 32-bit numbers in hexadecimal symbolized as they are in C (for example, 0x1230abde). How can easily read these in Mathematica?

share|improve this question
up vote 5 down vote accepted

How about:

data = {"0x1", "0xff", "0x1230abde"};
FromDigits[StringTrim[#, "0x"], 16] & /@ data

{1, 255, 305179614}
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.