Numbers are a fundamental part of everyday life. We use numbers to count, measure, and calculate. But have you ever wondered how computers understand and work with numbers? The answer lies in number systems.
A number system is a way to represent numbers using a consistent set of symbols or digits. Different number systems use different bases or radices, which determine how many unique digits are used and how numbers are structured.
The most familiar number system is the decimal system, which uses base 10. This means it uses 10 digits (0 to 9) and each digit's position represents a power of 10. Computers, however, primarily use the binary system (base 2) because it aligns perfectly with their electronic on/off states.
Other important number systems include octal (base 8) and hexadecimal (base 16), which are often used as shorthand to represent binary numbers more compactly.
Understanding these number systems and how to convert between them is essential for anyone studying Information and Communication Technology (ICT), especially for competitive exams.
The base or radix of a number system is the number of unique digits, including zero, that the system uses to represent numbers. For example:
Each digit's position in a number has a positional value, which is the base raised to the power of the digit's position index (starting from 0 at the rightmost digit).
Let's explore the main number systems used in computing:
| Number System | Base (Radix) | Digits Used | Example Number |
|---|---|---|---|
| Binary | 2 | 0, 1 | 1011 (binary) |
| Octal | 8 | 0 to 7 | 725 (octal) |
| Decimal | 10 | 0 to 9 | 156 (decimal) |
| Hexadecimal | 16 | 0 to 9, A to F | 3F (hexadecimal) |
Binary uses only two digits: 0 and 1. Each digit is called a bit. Computers use binary because their circuits have two states: ON (1) and OFF (0). For example, the binary number 1011 represents the decimal number 11.
Octal uses digits from 0 to 7. It is often used as a shorthand for binary because each octal digit corresponds exactly to three binary digits (bits). For example, octal 725 corresponds to a binary number.
This is the standard number system we use daily. It uses digits 0 through 9. Each position represents a power of 10. For example, the number 156 means \(1 \times 10^2 + 5 \times 10^1 + 6 \times 10^0\).
Hexadecimal uses sixteen symbols: digits 0-9 and letters A-F, where A=10, B=11, ..., F=15. It is widely used in computing to represent binary data more compactly. For example, hexadecimal 3F equals decimal 63.
Converting numbers between different bases is a key skill. There are two main methods:
graph TD A[Start with Decimal Number] --> B[Divide by Base (2,8,16)] B --> C[Record Remainder] C --> D{Is Quotient 0?} D -- No --> B D -- Yes --> E[Read Remainders Bottom to Top] E --> F[Result: Number in New Base] G[Start with Number in Base] --> H[Multiply Each Digit by Base^Position] H --> I[Sum All Products] I --> J[Result: Decimal Number]Why read remainders from bottom to top? Because the first remainder corresponds to the least significant digit (rightmost), and the last remainder corresponds to the most significant digit (leftmost).
Binary arithmetic follows similar rules to decimal arithmetic but with only two digits (0 and 1). Let's look at the four basic operations:
Rules for adding two binary digits:
Explanation: Adding bit by bit from right to left, carrying over when sum exceeds 1.
Binary subtraction uses borrowing similar to decimal subtraction. When subtracting 1 from 0, borrow 1 from the next higher bit.
Binary multiplication is like decimal multiplication but simpler:
Multiply and add partial products accordingly.
Binary division is similar to decimal long division but uses binary subtraction and comparison.
Step 1: Divide 156 by 2 and record the remainder.
Step 2: Read the remainders from bottom to top:
10011100
Answer: Decimal 156 = Binary 10011100
110101 to decimal using positional multiplication. Step 1: Write the binary digits with their positional powers (rightmost bit is position 0):
Positions: 5 4 3 2 1 0
Digits: 1 1 0 1 0 1
Step 2: Calculate each digit x \(2^{position}\):
Step 3: Sum all values:
32 + 16 + 0 + 4 + 0 + 1 = 53
Answer: Binary 110101 = Decimal 53
1011 and 1101 step-by-step. Step 1: Write the numbers aligned:
1 0 1 1
+ 1 1 0 1
Step 2: Add bit by bit from right to left, carrying over when sum ≥ 2:
Step 3: Write the result:
11000
Answer: 1011 + 1101 = 11000 (binary), which is 24 in decimal.
3F to decimal. Step 1: Identify the digits and their decimal equivalents:
Step 2: Assign positional powers (rightmost digit position 0):
Step 3: Sum the values:
48 + 15 = 63
Answer: Hexadecimal 3F = Decimal 63
725 to binary by converting each digit to 3-bit binary. Step 1: Convert each octal digit to its 3-bit binary equivalent:
Step 2: Combine the binary groups:
111 010 101
Answer: Octal 725 = Binary 111010101
10110 minus 1101 with borrow explanation. Step 1: Align the numbers:
10110
-01101
Step 2: Subtract bit by bit from right to left:
Step 3: Final result after borrowing and subtraction:
01001
Answer: 10110 - 1101 = 1001 (binary), which is 9 in decimal.
101 and 11 stepwise. Step 1: Write the multiplicand and multiplier:
Multiplicand: 101
Multiplier: 11
Step 2: Multiply each bit of multiplier by multiplicand, shifting left accordingly:
Step 3: Add partial products:
101
+1010
= 1111
Answer: 101 x 11 = 1111 (binary), which is 15 in decimal.
When to use: To quickly convert between binary and octal/hexadecimal without full decimal conversion.
When to use: During quick decimal conversions in exams.
When to use: For faster and error-free binary subtraction.
When to use: While converting hexadecimal to decimal or binary.
When to use: For quick verification and calculations during exams.
Progress tracking is paywalled — subscribe to mark subtopics as understood and save your streak.
Go to practice →