Python escape character

Source: Internet
Author: User
Raw string

Sometimes we don't want to let the escape character take effect, we just want to show the original meaning of the string, which is to use R and R to define the original string. Such as:

Print R ' \t\r '

Actual output is "\t\r"

Escape Character Description
\ (at end of line) continuation character
\ \ backslash Symbol
\ ' Single quotation mark
\ "Double quotation marks
\a Bells
\b Backspace (Backspace)
\e Escape
\000 Empty
\ nthe line break
\v Portrait tab
\ t Transverse tab
\ r Enter
\f Page Change
\oyy octal number yy represents the character, for example: \o12 represents a newline
\xyy the character represented by the decimal number yy, for example: \x0a represents a newline
\other other characters are output in normal format

Python escape character

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.