How is data stored?
]Before you go into coding, it is important to understand how computers understand and store data.
The number system we use (0-9) is called a Decimal system.
But computers understand what is called a Binary system.
In a Binary system, there are only 2 numbers: 0 and 1. That's right, you heard it right! Every number is a combination of 1's and 0's. For example:
Decimal -> Binary
0 -> 0
1 -> 1
2 -> 10
3 -> 11
4 -> 100
5 -> 101
6 -> 110
7 -> 111
8 -> 1000
9 -> 1001
The “binary” format is used because an ON can be interpreted to mean a 1 and an OFF could be seen as a 0.
Thus the two possibilities for a binary digit can be mapped to the on/off the computer actually uses.
This means it can manipulate those on/off signals to simulate arithmetic using the binary numbering system.
Even letters like A, B, C, D.. are stored in binary format