私信  •  关注

I-am-developer-9

I-am-developer-9 最近创建的主题
I-am-developer-9 最近回复了
3 年前
回复了 I-am-developer-9 创建的主题 » 函数调用期间未调用Python input()
inputCheck("Do you know the rules?\n", rules(), "Ok. Starting game...")

在运行函数时,不需要在规则之后使用任何paranthese(),而需要将函数作为参数传递。这样写:-

inputCheck("Do you know the rules?\n", rules, "Ok. Starting game...") 

这里还有:-

if yes_no.lower() == "n" or "no":
   function

您需要在函数后添加(),写:-

if yes_no.lower() == "n" or "no":
  function()

让我知道它是否解决了问题