What about the break keyword. When you want to stop the loop just use the break
I need to make an algorithm in which the person types a login and password and he has three attempts, I did a "while x <= 3" (ox has a value of 0) and then an if inside the while with the login and password condition . But how do I stop while asking for login and password 3 times even hitting the login and password on the first or second attempt?
Python: Stop a while when a condition do if it's true?