+ 2

Alguien me puede explicar registation system, usando try/ raise/ except por favor

6th Feb 2021, 10:06 PM
Matias Benegas
Matias Benegas - avatar
8 Réponses
+ 2
try: name = input() #your code goes here if name.lenght > 3 : print("Account Created") raise ValueError("Invalid Name") except: print("Invalid Name")
7th Feb 2021, 1:09 AM
Matias Benegas
Matias Benegas - avatar
+ 2
Remplaza: if len(name) < 3: print("Account Created") raise ValueError("Invalid Name") Con: if len(name) < 4: print("Account Created") raise ValueError
7th Feb 2021, 2:12 AM
Paula Campbell
Paula Campbell - avatar
+ 2
try: name = input() #your code goes here if name.lenght >= 4 : print("Account Created") raise ValueError except: print("Invalid Name")
7th Feb 2021, 2:41 AM
Matias Benegas
Matias Benegas - avatar
+ 2
try: name = input() if len(name) < 4: raise ValueError else: print("Account Created") except: print("Invalid Name")
7th Feb 2021, 11:47 PM
Paula Campbell
Paula Campbell - avatar
+ 2
De nada :)
7th Feb 2021, 11:52 PM
Paula Campbell
Paula Campbell - avatar
+ 1
Gracias....!
7th Feb 2021, 2:12 AM
Matias Benegas
Matias Benegas - avatar
+ 1
Intente asi pero no me dio el resultado....
7th Feb 2021, 3:22 AM
Matias Benegas
Matias Benegas - avatar
+ 1
Ok...gracias
7th Feb 2021, 11:51 PM
Matias Benegas
Matias Benegas - avatar