Character Sets - ASCII and Unicode

A character set is all of the characters that a computer can display*. All forms of data are stored inside the computer as numbers, and that includes text. Each character (or symbol) is represented by its own numeric code. The two character sets you need to know about for GCSE Computer Science are ASCII (American Standard Code for Information Interchange) and or Unicode.

Note that you aren't required to know any of the individual codes for your GCSE exam, but you are expected to know that they are in alphabetic order - you are commonly given the code for one letter and asked for another, e.g. if A is 65, then what is C?

is represented by the code

To see characters with higher codes, change the range of the slider using the offset below:

Notice that upper and lower case letters have different codes. Some Unicode characters are multi-coloured (look in the range 9-10,000). Note that not all characters are visible - there are things like spaces, carriage returns and line feeds that are invisible on a web-page. Not all Unicode values are assignment to characters, which is why there are gaps in the list of offsets. For ease of programming, only 16 bits are used for character codes in this example.

Although text files tend to be relatively small (compared with sounds and images, for example), you can still use compression techniques to make the file smaller.

* the instruction set is a similar idea, it's the set of instructions that a processor can execute.