Hello Team, Can someone please tell me why the below code does not work correctly? Here is the problem: Once I run the program and type in a couple of wrong answers and then type in the correct answer I still get the wrong response (e.g "No that is wrong! Try again.") But if I type in the correct answer first I get the correct response.
I also should add that if I don't use "use strict" and rename my variable without "my". The code then works as it should. regards, Jaimee #!/usr/bin/perl -w use strict; print ("What is 7 times 7? \n"); chop(my$input_answer = <STDIN>); my$answer = 49; until($input_answer == $answer) { print ("No that is wrong! Try again. \n"); chop(my$input_answer = <STDIN>); } print("You got it!!\n"); -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]