Example:

Example:
Memory device in state 0  Memory device in state 1 


can be in one of 2^{n} states !
A row of 3 switches can be in one of 2^{3} = 8 states.
The 8 possible states are given in the figure above.
Recall: we can use numbers to represent marital status information:

Example:

The representation scheme has a chic name:

Note to lecturer:


That means that you can only use the digits 0 and 1 to write a binary number
Example: some binary numbers

Binary number  Value encoded by the binary number 

d_{n1} d_{n2} ... d_{1} d_{0}  d_{n1}×2^{n1} + d_{n2}×2^{n2} + ... + d_{1}×2^{1} + d_{0}×2^{0} 
Example:
Binary number  Value encoded by the binary number 

0  0×2^{0} = 0 
1  1×2^{0} = 1 
10  1×2^{1} + 0 ×2^{0} = 2 
11  1×2^{1} + 1 ×2^{0} = 3 
1010  1×2^{3} + 0×2^{2} + 1×2^{1} + 0×2^{0} = 8 + 2 = 10 
(Read: there are binary 10 (= 2) types of people: those who understand binary (numbers) and those who don't)






Therefore, one byte can store one of 256 possible values
(You can store the number 34 into a byte, but you cannot store the number 556, the value is out of range)

Schematically:
A 16 bits memory cell can store one of 2^{16} = 65536 different patterns.
Therefore, it can represent (larger) numbers ranging from: 0 − 65535.
Example: how a computer can use 2 consecutive bytes as a 16 bits memory cell:
The bytes at address 0 and address 1 can be interpreted as a 16 bits memory cell (with address 0)

