Summary of ASCII and Unicode,utf-8

Source: Internet
Author: User

ASCII is a byte store in English and special characters, does not support the processing of Chinese. Unicode occupies two bytes and can be stored in Chinese. The Utf-8 occupies three bytes and can be converted in English and Chinese according to the contents of the storage.

Python interpreter is not supported in Chinese, the default is the ASCII format storage, so generally at the beginning of the program to add #_*_coding = Utf-8_*_ The program has been utf-8 format to be stored to solve the Chinese input problem.

The function of converting variable format into a program: Encode (' Utf-8 ') is used to transcode, so it is possible to transcode the target to utf-8 format, decode (' Unicode ') is used for decoding, and the target can be decoded to Unicode format.

Summary of ASCII and Unicode,utf-8

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.