This section provides a tutorial example on how to run the character encoding sample program with ISO-8859-1 and US-ASCII encodings. Character encoding US-ASCII is a subset of ISO-8859-1.
Now, let's run my sample program, EncodingSampler.java, again with another encoding, ISO-8859-1:
Obviously, the result shows that encoding US-ASCII has a smaller character set: 0x0000 - 0x007F.
Encoding ISO-8859-1 has a larger character set: 0x0000 - 0x00FF.
In another word, US-ASCII is a subset of ISO-8859-1.