In the interpreter, when I'm writing the code
When you type to the shell:
It displays the string variable created from what your wrote, and python defaults to ' usage. So you get:
which, when you think about it, is the exact same string you wrote! You used "" to denote the string and escaped the extra ", but python uses in the shell ' and escapes the extra one in the it ' s.
To show the string properly use the print method which reads the escapes properly. I guarantee printing your version or the version your shell returns will both yield what you wanted.
On a side note you can use triple quotes to skip escapes all together:
The caveat is you can't use triple double quotes, because python will think the end of your string is part of the string enclosure.