Ask your own question, for FREE!
Computer Science 8 Online
OpenStudy (aroub):

what's 'hexadecimal' ? and please give valid and invalid examples about it so I could understand :)

OpenStudy (farmdawgnation):

Hexadecimal is a numbering system where in addition to the digits 0-9, you also have A-F that serve as digits. So, it's considered a "base 16" numbering system. For example: 0xA = 10 in decimal 0xFF = 255 in decimal (the 0x out in front is just notation to tell you a particular number is hexadecimal)

OpenStudy (anonymous):

Hexadecimal describes a base-16 number system. That is, it describes a numbering system containing 16 sequential numbers as base units (including o) before adding a new position for the next number The hexadecimal numbers are 0-9 and then use the letters A--f..one hexadecimal digit can represent the arrangement of four binary digits To convert hexadecimal F8 to binary, write down the binary for F first, then the binary for 8. F 8 1111 1000 So, the answer is 11111000.

OpenStudy (anonymous):

decimal base 10: 0 1 2 3 4 5 6 7 8 9 hexadeciaml base 16: 0 1 2 3 4 5 6 7 8 9 A B C D E F in computers everything is in binary (0 and 1) and because of this all numbers are very long so hexadecimal is used to make code more readable and it's easy to convert since 2^4=16

OpenStudy (aroub):

Umm.... okay what about I tell you some examples and you tell if it's valid or not please :) #FF3366 #AAAAAA #FFCCCC #004466

OpenStudy (aroub):

AOOH! I think I get it, thanks everyone =)

OpenStudy (aroub):

Okay I think I don't.... why is this: #FFCCCC valid?

OpenStudy (farmdawgnation):

Well, it doesn't include any letter higher than F. Why do you think it wouldn't be valid?

OpenStudy (anonymous):

You should google "CONVERTING HEXADECIMAL TO BINARY"

OpenStudy (aroub):

Why is this #AAAAAA invalid then? it does not include any letter higher than F right?

OpenStudy (farmdawgnation):

That doesn't look invalid to me. Did someone say it is?!? o.O

OpenStudy (anonymous):

yup

OpenStudy (aroub):

Yes I have like an 'answer key' ( but it might be wrong though) I just need to know WHY @ Gary, is it valid or invalid?

OpenStudy (anonymous):

it is valid

OpenStudy (farmdawgnation):

Now, granted - that is a *valid* Hexadecimal number. It may not be a number valid for what you need to use it for. Without any context we can't really tell you much more than whether or not it works as a number.

OpenStudy (anonymous):

Hexadecimal's major use is that it is easier for humans to read hexadecimal numbers than binary numbers

OpenStudy (anonymous):

decimal numbers more readable :P but conversion from binary to decimal is complex

OpenStudy (aroub):

What can use 'hexadecimal' for?

OpenStudy (aroub):

can you*

OpenStudy (anonymous):

I already told it, and Gary Ahuja said it once more :D

OpenStudy (aroub):

because I'm using it for colours...

OpenStudy (anonymous):

let's say you have memory addresses 32 bits 10101010101011101110001100000001 10101010101011101110001100001111 it's pain to read but in hexadecimal it would be AAAEE301 AAAEE30F

OpenStudy (anonymous):

The main reason why we use hexadecimal numbers is because it is much easier to express binary number representations in hex than it is in any other base number system. Computers do not actually work in hex . Lets look at an example, using a byte. Bytes are typically 8 bits, and can store the values 0 – 255 (0000 0000 – 1111 1111 in binary). For people, expressing numbers in binary is not convenient. Hope You got it !!

OpenStudy (aroub):

I didn't say 'why' do you use it. Anyway, my point is, is it different if you used it in different ways?

OpenStudy (anonymous):

noo

OpenStudy (aroub):

Okay, cool thanks aloot! :D

OpenStudy (anonymous):

what do you mean use it in different ways?

OpenStudy (aroub):

before answering your question... the numbers: 10101010101011101110001100000001 10101010101011101110001100001111 ^ what do they represent?

OpenStudy (anonymous):

i just wrote random numbers

OpenStudy (aroub):

Because these numbers that I wrote; #FF3366 #AAAAAA #FFCCCC #004466 ^They represent colours... so the answer to your question "what do you mean use it in different ways?" like colours and I don't know if you use it in other ways... so that's why I'm asking...

OpenStudy (anonymous):

farmdawgnation look this http://openstudy.com/#/updates/4edf93e3e4b05ed8401af5c3

OpenStudy (anonymous):

depending on the type of color (i.e., number of bits) your referring, taking in consideration that your using RGB and that each hexadecimal unitary symbol (i.e., 0 to F only not 0F, or AFF, or BCC, etc) can represent at most a 4 bit number (hex F = bin 1111) http://www.mathsisfun.com/hexadecimal-decimal-colors.html Unless the color code is not in the right code system or not recognized no apparent reason for it to be invalid.

OpenStudy (anonymous):

an extension to this question. write an assembly language program to convert a given number(decimal) to its hexa decimal equivalent.

OpenStudy (farmdawgnation):

You may want to post this as a new question, but you'll also need to specify *which* assembly language you need to use. There are several. :)

OpenStudy (anonymous):

8051 MC

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!