We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Date: 2014-07-1 Title: str()与repr()的区别 Tags: Python Category: It
>>> word="hello\t world!\nhello motto!" >>> str(word) 'hello\t world!\nhello motto!' >>> repr(word) "'hello\\t world!\\nhello motto!'" >>> print str(word) hello world! hello motto! >>> print repr(word) 'hello\t world!\nhello motto!' >>>
>>> str(0.1) '0.1' >>> repr(0.1) '0.10000000000000001'
There was an error while loading. Please reload this page.