0

Can anyone tell my why this code does not work to solve the end of chapter python regex problem? Thanks. I apologize if I have p

import re password = input() if re.search(r"[A-Z][0-9]*", input()): print("Password created") else: print("Wrong format") #your code goes here import re password = input() if re.search(r"[A-Z][0-9]*", input()): print("Password created") else: print("Wrong format") #your code goes here

11th Mar 2022, 12:30 AM
Chris
Chris - avatar
2 Réponses
+ 1
That was the problem. I didnt even realize, I had been using the input() function within the regex expression instead of using the password input variable that I should have used. Thanks. It worked!
11th Mar 2022, 1:04 AM
Chris
Chris - avatar