私は単純な小さな平均計算機をやっています。
def avg():
sumSoFar = 0
count = 0
numCount = 0
while numCount != "":
numCount = eval(input("Please enter a number or press <enter> to quit: "))
sumSoFar += numCount
count += 1
print("The average of these numbers is: ", sumSoFar/count)
そして、私はエラーを受け取り続けます:
numCount = eval(input("Please enter a number or press <enter> to quit: "))
File "<string>", line 0
Syntax Error: unexpected EOF while parsing
問題は何ですか?