How do you display the characters \ and "?
A double quote can be displayed by using a single quote in python.
print('"')
Output:
"
---------------------------------------------------------------------------------------------
A backslash(\) needs to be printed or displayed in two different ways because backslash(\) is an escaping character.
A way of printing a backslash that doesn't involve escaping is to pass its character code to chr
:
>>> print(chr(92))
Output:
\
A backslash needs to be escaped with another backslash.
print('\\')
Output:
\