# How To Convert Memory Locations To Bytes

#### Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

•  Subject
• Author
• Posted on
user programs at 10000H to 9FFFFH (with the first location being
10000H and the last one 9FFFFH) how do you determine the total number
of bytes available?

If you subtract 10000H from 9FFFFH and convert that to Decimal, would
that give you the number of bytes?

Thanks

Re: How To Convert Memory Locations To Bytes

No, you would be short by one.  And you don't have to convert to decimal
unless that is how you need the answer.  The number of bytes in the address
range of 10000H and 9FFFFH is:

(9FFFF - 10000) + 1 = 90000 (hexadecimal)
= 589824 (decimal)
= 2200000 (octal)
= 10010000000000000000 (binary)

Sure.

--
========================================================================
Michael Kesti            |  "And like, one and one don't make
We've slightly trimmed the long signature. Click to see the full one.