0

Hi somebody can help me please? It’s a bug 🥲

pin = int(input()) try: print ("PIN code is created") except (ValueError, NameError, TypeError, SyntaxError, ImportError): print ("Please enter a number")

13th May 2021, 3:52 AM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
11 Réponses
+ 1
try: pin = int(input()) print("created") except: print("enter number")
13th May 2021, 4:16 AM
TOLUENE
TOLUENE - avatar
+ 1
password = input() repeat = input() if password == repeat: print('Correct') else: print('Incorrect') Conditional is one of the basic and the simplest subject in python/programing, you should review it, https://www.sololearn.com/learning/2277/
13th May 2021, 10:18 AM
Endalk
Endalk - avatar
+ 1
Thanks Calvin
14th May 2021, 11:53 PM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
0
its working
13th May 2021, 4:15 AM
Ireneo language
0
Example of pin : hh88 tells me error
13th May 2021, 4:16 AM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
0
Works for numbers
13th May 2021, 4:17 AM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
0
Yes
13th May 2021, 4:17 AM
TOLUENE
TOLUENE - avatar
0
Thanks it works now!!! 💙
13th May 2021, 4:19 AM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
0
Would you mind helping me with this code: password = input() repeat = input() def validate(text1, text2): I need they match and print correct or incorrect depending of the match
13th May 2021, 4:26 AM
Hemmily Beatriz Castillo Arrieta
Hemmily Beatriz Castillo Arrieta - avatar
0
Here's the correct way of catching all the errors possible in your code: try: pin = int(input()) print("The PIN has been created") except TypeError: print("Please enter a valid number") # Hope this helps
14th May 2021, 7:27 PM
Calvin Thomas
Calvin Thomas - avatar
- 1
wut
13th May 2021, 4:13 AM
Ireneo language