1. Introduction to Encoding
Character encoding maps each character to a unique binary number so that computers can store and process text.
Different encoding schemes use different numbers of bits per character.
2. ASCII (American Standard Code for Information Interchange)
ASCII is a 7-bit encoding scheme that represents 128 characters (0-127). It includes uppercase letters (A-Z), lowercase letters (a-z), digits (0-9), punctuation, and control characters.
Examples:
'A' = 65 (1000001₂)
'a' = 97 (1100001₂)
'0' = 48 (0110000₂)
Space = 32
'$' = 36Extended ASCII uses 8 bits and includes 256 characters.
3. ISCII (Indian Script Code for Information Interchange)
ISCII is an 8-bit encoding scheme for Indian languages (Devanagari, Bengali, Tamil, Telugu, etc.) developed by the Bureau of Indian Standards.
Supports 10 Indian scripts and uses a common phonetic base.
4. Unicode
Unicode is a universal encoding standard that supports characters from all languages worldwide. It assigns a unique code point (U+xxxx) to each character.
Examples:
U+0041 = 'A' (Latin capital letter A)
U+0905 = 'अ' (Devanagari letter A)
U+20B9 = '₹' (Indian Rupee sign)
U+1F600 = '😀' (grinning face emoji)5. UTF-8, UTF-16, UTF-32
| Scheme | Bytes per character | Description |
|---|---|---|
| UTF-8 | 1 to 4 (variable) | Backward compatible with ASCII, most efficient for web |
| UTF-16 | 2 or 4 (variable) | Uses 2 bytes for most characters, 4 for emoji/rare |
| UTF-32 | 4 (fixed) | Fixed width, simple but uses more space |
6. Comparison of Encoding Schemes
| Feature | ASCII | ISCII | Unicode (UTF-8) |
|---|---|---|---|
| Bits | 7 (extended 8) | 8 | 8-32 (variable) |
| Characters | 128 (extended 256) | ~256 | 1,114,112 |
| Indian support | No | Yes | Yes |
| Global use | Limited | India only | Worldwide |
7. Revision Questions and Answers
Very Short Answer Questions
1. What does ASCII stand for?
American Standard Code for Information Interchange.
2. How many characters can 7-bit ASCII represent?
128 (2⁷).
3. What is the ASCII value of 'A'?
65.
4. Which encoding scheme supports Indian languages?
ISCII and Unicode.
5. What is the most common encoding for the web?
UTF-8.
Short Answer Questions
1. Differentiate between ASCII and Unicode.
ASCII is a 7-bit encoding for 128 English characters. Unicode is a universal encoding with over a million characters from all languages. UTF-8 is Unicode's variable-length encoding compatible with ASCII.
2. What is ISCII? Which organization developed it?
ISCII (Indian Script Code for Information Interchange) is an 8-bit encoding for 10 Indian scripts, developed by the Bureau of Indian Standards.
Long Answer Questions
1. Explain UTF-8 encoding with its advantages.
UTF-8 uses 1 byte for ASCII characters (backward compatible), 2 bytes for European/middle-eastern scripts, 3 bytes for Asian scripts, and 4 bytes for rare characters/emoji. Advantages: space-efficient, backward compatible with ASCII, supports all languages, most common web encoding.