I have this code:
secret_word = "secretword"
guess = ""
def askForGuess():
    guess = input("Introduce the secret word :")
    print(guess,secret_word)
    
while guess != secret_word:
    askForGuess()
    
 
print("You've won!")
If I call askForGuess() inside the while statement it will never print 'You've won!' not even if I introduce the secret word correctly. However, if I just simply paste askForGuess() code inside of the while statement it works. Does anyone know why?
 
     
     
     
     
    