所以,我一直在研究“幸运之轮”的Python实现已经有一段时间了,经过一段时间的测试我到目前为止,它抛出了这个错误:
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
wheel_of_fortune()
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 50, in wheel_of_fortune
player1firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, 0, 0, 0)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 190, in player1firstturn
player1do(prize, choice, player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 229, in player1do
player1firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 87, in player1firstturn
player1firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 167, in player1firstturn
player2firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 439, in player2firstturn
player2do(prize, choice, player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 478, in player2do
player2firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 416, in player2firstturn
player3firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 723, in player3firstturn
player3do(prize, choice, player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 762, in player3do
player3firstturn(player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
File "C:/Users/Harry/Documents/randompythonprograms/e.py", line 693, in player3firstturn
player1(player1choice, player1, player2, player3, text, blank_text, letters, consonants, vowels, vwit, player1amount, player2amount, player3amount)
TypeError: 'str' object is not callable
任何人都可以向我解释“错误警告”吗? 顺便说一下,到目前为止我在这里: https://gist.github.com/HarrySlaughter/d8481874ec401cb0a78defd75ad9fd72