我試圖去學習如何使用ascii
功能在Python 3如何在Python 3中使用ascii函數?
文檔讀取
ascii(object)
As repr(), return a string containing a printable representation of an object, but escape the non-ASCII characters in the string returned by repr() using \x, \u or \U escapes. This generates a string similar to that returned by repr() in Python 2.
然而,當我嘗試使用print ascii("c")
我收到的錯誤:
print ascii("c")
^
SyntaxError: invalid syntax
如何使用此功能?
'print'在Python 3 – Blender