Deep inside a computer, the letter 'A' you type isn't stored as a letter at all - it's stored as a number. In the widely used ASCII text-encoding standard, what number represents the uppercase letter 'A'?
- 97
- 48
- 13
- 65
Why D? And why not the others?
Correct answer: D. 65
ASCII (American Standard Code for Information Interchange), finalised in the 1960s, assigns every standard keyboard character a unique number so it can be stored and processed as binary; the uppercase letter 'A' is assigned the number 65, with the rest of the uppercase alphabet following consecutively from there ('B' is 66, 'C' is 67, and so on). The option giving 97 is a genuine ASCII code, but for the lowercase letter 'a', not the uppercase 'A'; the lowercase letters sit exactly 32 higher than their uppercase counterparts, which is why code can switch case just by adding or subtracting 32. The option giving 48 is also a real ASCII code, but for the printable digit character '0', an entirely different symbol from any letter. The option giving 13 is the ASCII code for carriage return, a control character used to mark the start of a new line on old teletype printers, not a printable letter at all.
Source: BBC Bitesize GCSE Computer Science: Data representation - character sets