If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Computers and the Internet

Course: Computers and the Internet>Unit 1

Lesson 2: Binary numbers

The binary number system

Binary numbers form the basis of computing systems. Binary numbers contain only the digits 0 or 1, or bits, where each bit represents a power of two. To convert binary to decimal, multiply each bit by its corresponding power of two and add the results.

.
Created by Pamela Fox.

Want to join the conversation?

• "It took us 8 bits to represent a number that only took 2 digits to represent in the decimal system."

01010101 Uses 8 bits, but I can make it with 7: 1010101.

So if we can add 0's in the front, then can't I just say,
"It took us 8 bits to represent a number [01010101] that takes a whole 10 digits to represent [0000000085] in the decimal system."

It would be nice if the video at least pointed out that you could do it in 7... anyone with me?
• From the author:That's a really good point. YouTube doesn't make it particularly easy to edit videos, but I'll try to edit it if I get the chance. I very much agree.
• How many bytes does it take to equal one KB
(1 vote)
• 1024 bytes
• Why do they leave the 0 there, typically its not supposed to do that, like I wouldn't say 010, I would just say 10.
• Binary numbers are generally only used in the context of computers which use a fixed number of bytes/bits to represent numbers. For example, a computer may use 32 bits to represent the number 13 even though 13 would only need 4 bits. This leaves 28 preceding 0s in the binary representation of 13. So, in general, we are less concerned about getting rid of preceding 0s when we write out binary numbers.
• *Humming intesifies
• how can represent the number 10389810 in binary language
• 100111101000100100110010
• how do you figure out how many bytes does it take to equal one KB?
(1 vote)
• How we can represent 53426 into binary numbers??
(1 vote)
• ``53426= 2^15 + 2^14 + 2^12 + 2^7 + 2^5 + 2^4 + 2^1= 1*2^15 + 1*2^14 + 0*2^13 + 1*2^12 + 0*2^11 + 0*2^10 + 0*2^9 +  0*2^8 + 1*2^7 + 0*2^6 + 1*2^5 + 1*2^4 + 0*2^3 + 0*2^2 +   1*2^1 + 0*2^0= 1101000010110010``
(1 vote)
• how do you figure out how many bytes does it take to equal one KB?
(1 vote)
• 1 kilobyte = 1000 bytes. Kind of like how one kilometer = 1000 meters.
(1 vote)
• If you're making a binary number can you just make them all ones? Like if I wrote "1 1 1 1" would that be equal to 20, or would that not work, the numbers need to be ones and zeros?
(1 vote)
• A binary number can consist of entirely 1s, so 1111 is a valid binary number. (However, 1111 is not equal to 20; it equals 15.) In fact, any number equal to 2^x - 1 (for any positive integer x) will be entirely 1s when written in binary.
(1 vote)
• How are negatives represented in the binary system? Does the negative symbol (and other symbols and special characters for that matter) have its own binary code?