earlier, I had posted a problem in which I was advised to look at it in terms of hex values and not binary values, so how do i do this in c++?
As an example lets suppose that int n = 1234, now instead looking at binary I would like to look at it in terms of hex values, so I would like to look at it in by looping through the int and reading 1's hex value, then 2 and so on...
But, an int is a 4 byte number, this doesn't correlate to 1 being a hex char, 2 being a hex char etc and all added together.
In general hex goes from 0x00 = 0 to 0xFF = 255 for each byte. 0xFFFF (2bytes) maximum value is 65535 (because 0xFFFF = 65535). So the data type 'short' which is 2 bytes can have a maximum value of 65535 (if unsigned).