You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
Computers store all data as binary numbers, including text. A character encoding system assigns a unique binary number to each character (letter, digit, symbol). OCR J277 Section 2.6 requires you to understand both ASCII and Unicode.
A character encoding is a mapping between characters and numbers. When you type the letter "A" on a keyboard, the computer stores a number (65 in ASCII). When the computer displays that number, it shows the character "A" on screen.
Every character must have a unique number, and both the sender and receiver of data must agree on which encoding system to use. Otherwise, characters may be displayed incorrectly.
ASCII was developed in the 1960s and uses 7 bits per character, giving 2^7 = 128 possible characters. These include:
| Range | Characters | ASCII codes |
|---|---|---|
| Uppercase letters | A-Z | 65-90 |
| Lowercase letters | a-z | 97-122 |
| Digits | 0-9 | 48-57 |
| Punctuation and symbols | ! @ # etc. | Various |
| Control characters | Enter, Tab, Backspace | 0-31 |
| Space | (space) | 32 |
| Character | ASCII (denary) | ASCII (binary, 7-bit) |
|---|---|---|
| A | 65 | 1000001 |
| B | 66 | 1000010 |
| Z | 90 | 1011010 |
| a | 97 | 1100001 |
| 0 | 48 | 0110000 |
| Space | 32 | 0100000 |
OCR Exam Tip: You do not need to memorise the entire ASCII table, but you should know that A = 65, a = 97, and 0 = 48. Notice that lowercase letters are 32 higher than their uppercase equivalents.
Standard ASCII uses 7 bits, but most computers use 8-bit bytes. Extended ASCII uses all 8 bits, providing 2^8 = 256 characters. The extra 128 characters include accented letters (e.g., e, u), additional symbols, and line-drawing characters.
ASCII has significant limitations:
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.