Binary

Binary is a base 2 number system. Each digit can only be a 0 or a 1. One binary digit is called a bit.

Bit

A bit is the smallest amount of data that a computer can handle at once. It is basically an on/off switch, either representing a 1 (on) or 0 (off). At the most primal level of your computer, everything is a stream of bits. 8 bits together make a byte.

Byte

A byte is a series of 8 bits (0 and 1's). For a long time in the history of computing, CPU's could only process one byte at a time, thus, giving the term 8-bit computer. A byte has a value range of 0 to 255 (in decimal). 1024 bytes is one kilobyte.

Bytes are usually written as a two digit hexadecimal number. For example, $01 is the number 1 and $0a is the number 10.

Binary Coded Decimal (BCD)

Binary coded decimal is the technique of encoding decimal numbers in binary. To accomplish this, four bytes are reserved for each digit and each set of four bits is used to represent a number between 0000 (0) and 1001 (9). In CPUs such as the 6502, two numbers can be stored in one byte — the word length of the 6502. When more than one digit is packed into a word, this is sometimes called packed BCD.

Binary Math

Binary Addition

Binary addition is exactly the same as decimal addition, with the sole exception that only 0's and 1's are used.

Binary Additon

 0101
+1010
 ----
 1111

Related Pages

Categories: Binary : Computer Science : Data
page_revision: 4, last_edited: 1238159057|%e %b %Y, %H:%M %Z (%O ago)