Conversion from Chinese characters to location code

zhaozj2021-02-16  64

The school wants us to fill in the situation of the graduates, the type of machine card, the name is to use a location code. If you use the program to query, it is the database lookup, I want to compose one should be very simple, just go online to see if there is any Similar programs, then I use its database yourself to realize one, let me find an article how to implement the conversion from the Chinese characters to the location code, huh, you can use the database.

The location code is a code corresponding to the Chinese character, with a four digit, the first two digits are called from 01 to 94, and the latter two bits range from 01 to 94. The first half of a Chinese character is a character of the ASCI Id code "160 area code", the latter half is the character of the ASCII code "160 bits".

For example, the location code of "Liu" is 3385, which is integrated into the code 33-bit code 85, which is composed of two characters of the ASCI II code of 160 33 = 193 and 160 85 = 245.

I use a simple console program to implement the following #include #include void main () {char i [64]; while (1) {cout << "Enter a single letter to exit" << ENDL; CIN >> I; IF (Strlen (I) == 1) Break; for (int J = 0; j

转载请注明原文地址:https://www.9cbs.com/read-16871.html

New Post(0)