In the below example, we are using some of the escape sequence and their outputs, we are printing single quote (\'), double quotes (\"), printing path (double slash) (\\) and using hexadecimal values (\x).
Hi, I'm IncludeHelp
"Hello world"
D:\work_folder\python_works
This is IncludeHelp
Ignoring Escape Sequences
To ignoring escape sequences in the string, we make the string as "raw string" by placing "r" before the string. "raw string" prints as it assigned to the string.
Program:
Output
Ignoring Escape Sequences
To ignoring escape sequences in the string, we make the string as "raw string" by placing "r" before the string. "raw string" prints as it assigned to the string.
Program:
Output
need an explanation for this answer? contact us directly to get an explanation for this answer