Hi, I need to set up an array where the indices are hexadecimal numbers. Is there any way i can do this without converting the hexadecimal numbers into decimal first?
A hexadecimal number is just as good as a decimal number. When your program is compiled, it's exactly the same as a decimal numer : It's converted to some binary stuff.
Hexadecimal is only a notation used to please the human eye / brain (Much easyer to read than binary (Like 1001001)).
MyArray[0x0f] is the same as MyArray[15]
Use whatever you prefer.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.