This is a simplified version I made of the problem I'm having
I have my Game() function that calls the other UpdateScore() and Score() functions, UpdateScore() adds 1 to computerScore, and Score() prints that updated value. But that value either doesn't get updated, what am I doing wrong?
import time
def Game():
condition = True
computerScore = 0
while (condition):
time.sleep(2)
UpdateScore(computerScore)
Score(computerScore)
def UpdateScore(computerScore):
computerScore = computerScore+1
return
def Score(computerScore):
computerScore = UpdateScore(computerScore)
print(computerScore)
Game()