Python 3 print without parenthesis

前端 未结 8 1729
一整个雨季
一整个雨季 2020-11-30 01:27

The print used to be a statement in Python 2, but now it became a function that requires parenthesis in Python 3.

Is there anyway to suppress these par

8条回答
  •  温柔的废话
    2020-11-30 02:16

    You can't, because the only way you could do it without parentheses is having it be a keyword, like in Python 2. You can't manually define a keyword, so no.

提交回复
热议问题