Question of the day

Here you can talk about everything that's offtopic.

Moderator: Dust

Post Reply
User avatar
Etherus
Posts: 740
Joined: 01 Jan 1970 01:00
Contact:

Question of the day

Post by Etherus » 18 Aug 2007 18:05

Which of the following hex values represent 1 binary byte? (assume no leading zeros)

A: F
B: F0
C: FF0
D: F0F0

Answer has to be explained :P lol >.< go go dust!
Norla
Posts: 278
Joined: 01 Jan 1970 01:00
Contact:

Post by Norla » 18 Aug 2007 18:34

I think many people besides Dust are familiar with hexadecimals. Unfortunantly, ive forgotten most of it.
Image
Stormwern
Die-hard
Posts: 1006
Joined: 01 Jan 1970 01:00
Location: Sweden
Contact:

Post by Stormwern » 18 Aug 2007 18:59

1 byte in hex is one digit, so you probably mean A.
User avatar
Dust
The Boss
Posts: 9093
Joined: 01 Jan 1970 01:00
Contact:

Post by Dust » 18 Aug 2007 19:32

it's b...

A byte has 8 bits, a hex char can represent the values of four bits only. (four bits allow 2^4 = 16 different values... a byte 2^8 = 256).

F = 15
F0 = 240 = 15*16

BTW... in binary, that's

A 1111
B 11110000
C 111111110000
D 1111000011110000

Maybe you see why we use hex editors, and not decimal editors to change data the low level way :)
I do what I think is right. But I don't think that what I think is right can not be wrong.
User avatar
Etherus
Posts: 740
Joined: 01 Jan 1970 01:00
Contact:

Post by Etherus » 18 Aug 2007 19:45

LoL thanks Dust >.< your to smart >.<
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests