Problem Solving using C Language

0 of 77 lessons complete (0%)

Introduction to Computers

Number System

A numeral system (or system of numeration) is a writing system for expressing numbers; that is, a mathematical notation for representing numbers of a given set, using digits or other symbols in a consistent manner.

  • The value of each digit in a number can be determined using −
  • The digit
  • The position of the digit in the number
  • The base of the number system (where the base is defined as the total number of digits available in the number system)

Number system in computer system

A number system is a mathematical framework used for representing and expressing numbers. Different number systems use various bases to define how numbers are structured and understood. The most commonly used number systems are:

  1. Decimal Number System (Base 10):
    • Digits Used: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
    • Explanation: The decimal system is the standard system used by humans for everyday counting. It is a positional number system, meaning the position of a digit within a number determines its value (e.g., in 345, the digit 5 represents 5 units, 4 represents 40, and 3 represents 300).
    • Use Case: Almost all everyday arithmetic and measurements.
  2. Binary Number System (Base 2):
    • Digits Used: 0, 1
    • Explanation: The binary system is the foundation of digital computing. In this system, every number is represented using only two digits: 0 and 1. Each binary digit is called a bit, and combinations of bits represent different numbers (e.g., the binary number 1011 represents the decimal number 11).
    • Use Case: Used in computer systems, logic circuits, and digital communication.
  3. Octal Number System (Base 8):
    • Digits Used: 0, 1, 2, 3, 4, 5, 6, 7
    • Explanation: The octal system is less common but was historically used in computing. Each octal digit represents three binary digits, making conversions between binary and octal straightforward (e.g., the octal number 17 represents the binary number 001 111).
    • Use Case: Used in some computing applications, particularly older systems.
  4. Hexadecimal Number System (Base 16):
    • Digits Used: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F
    • Explanation: The hexadecimal system is widely used in computing, especially in programming and memory addressing. It is a compact way of representing binary data because one hexadecimal digit corresponds to four binary digits (e.g., the hexadecimal number 1A3 represents the binary number 0001 1010 0011).
    • Use Case: Memory addresses, color codes in web design, and low-level programming.