Page 36 - CA_Blue( J )_Class10
P. 36
IMPORTANT RANGES OF ASCII CODE
A to Z 65 to 90
a to z 97 to 122
0 to 9 48 to 57
There is one more version of the ASCII standard, which is known as Extended ASCII. It uses 8-bit numeric codes to
represent different character ranges from 0–256 characters.
Note: Open the notepad and press the Number keys: 6 and 5 while pressing the Alt key down, you
will see that the characters 'A' is written. Similarly, you can check other codes.
3.2.2 Unicode
Unicode (Universal Character Encoding Standard) earlier known as Universal Coded Character that defines the way
individual characters are represented in different types of documents such as text files, web pages, and other types of
documents. It supports a large number of characters from various languages like Hindi, English, French, etc. from all
around the world. Unlike ASCII and Extended ASCII encoding techniques, Unicode supports 8-bit to 32-bit encoding
mechanisms to represent character ranges from 0 to 1,000,000 characters. It represents characters in the form of 4
digit hexadecimal code preceded by '\u' (an escape sequence character). For example, the character 'A' is represented
as "\u0041". Some of the codes of different languages' characters are as follows:
Character Unicode
ल (Hindi Language Letter La) \u0932
प (Hindi Language Letter Pa) \u092A
€ (Euro sign) \u20AC
க (Tamil Language Letter Ka) \u0B95
If you simply use these Unicode value in a Java statement like given below:
System.out.println("\u0932");
System.out.println("\u092A");
System.out.println("\u20AC");
System.out.println("\u0B95");
You will get the following output:
3.2.3 Difference between ASCII and Unicode
ASCII UNICODE
21
Standard ASCII character set only supports 128 characters Unicode supports a wide range of characters (0–2 ).
(character range whose numeric value is between 0–127).
ASCII only uses one byte to represent each character. Unicode supports up to 4 bytes for each character.
The ASCII code requires less space. The Unicode requires more space.
3.3 ESCAPE SEQUENCES
A non-graphical character that is preceded by a backslash (\) and has a special meaning for the compiler is known as an
escape sequence character. Java has a total of 8 escape sequence characters. They are used to perform specific tasks
and are valid character literals.
3434 Touchpad Computer Applications-X

