ASCII code
In a computer, all data is stored and computed using binary numbers (because the computer represents 1 and 0, respectively, with high and low levels), for example, 52 letters (including uppercase) such as a, B, C, D, and 1, 2, and other commonly used symbols (example
such as *, #, @, etc.) are stored in the computer also to use a binary number to represent, and specifically with which binary numbers to indicate which symbol, everyone can contract their own set (this is called code), and if you want to communicate with each other without causing confusion, then we must
Using the same coding rules, the United States-related standardization organizations have introduced ASCII encoding, which uniformly stipulates which binary numbers are used to denote these common symbols.
The char type can accept a numeric range of values: 0-65536, the output will be converted to ASCII code.
Escape character
Give a special character assigned value to the char type
Assign a single quote ' to a char type
char c1 = ‘‘‘;
The above writing will be incorrect at compile time, the correct method should use the escape character, the slash in the Java language has the escape function, the correct wording is as follows:
char c1 = ‘\‘‘;
In my first program parsing, it contains the escape character, the tab \ t, and the output effect
Char type of Java--escape character