CBSE Class 10 Computer Applications Question 27 of 31

Python Revision — Question 15

Back to all questions
15
Question

Question 15

How are nongraphic characters represented in Python ?

Answer

Python allows us to have certain non-graphic characters in String values. These non-graphic characters can be represented by using escape sequences — represented by a backslash ( \ ) followed by one or more characters.

Some examples of non-graphic characters and their escape sequences are as follows:

Escape SequenceNon-Graphic Character
\aASCII Bell (BEL)
\nNew line character
\tHorizontal tab