2 回答

TA貢獻(xiàn)1895條經(jīng)驗(yàn) 獲得超7個(gè)贊
my_string
__repr__()
>>> print(my_string)why\does\it\happen?
>>> 'a\\b''a\\b'>>> len('a\\b')3
repr()
>>> print(repr(my_string))'why\\does\\it\\happen?'
\\
\n
\t
>>> print("this\text\is\not\what\it\seems")this ext\is ot\what\it\seems
\n
>>> print("this\\text\is\what\you\\need")this\text\is\what\you\need

TA貢獻(xiàn)1880條經(jīng)驗(yàn) 獲得超4個(gè)贊
\d
d
\d
\t
DeprecationWarning
SyntaxError
\Foo
\foo
添加回答
舉報(bào)