Challenge: Safely Auth
Note
These comments help you find the code that needs to be modified:
========== Modify code below ==========
========== Modify code above ==========
Swipe to start coding
You have implemented the login() function, which raises errors. Implement the safely_auth() function that uses the login() function and catches errors.
- Create a code block to track errors (mention the keyword).
 - Call the 
login()function in the error tracking block. - Catch the 
TypeErrorand save its info inside theerrorvariable. - Print the 
errorvariable (error info) in the console. - Catch the 
ValueErrorand save its info inside theerrorvariable. 
Oplossing
Bedankt voor je feedback!
single
Vraag AI
Vraag AI
Vraag wat u wilt of probeer een van de voorgestelde vragen om onze chat te starten.
Vat dit hoofdstuk samen
Explain code
Explain why doesn't solve task
Awesome!
Completion rate improved to 4.35
Challenge: Safely Auth
Veeg om het menu te tonen
Note
These comments help you find the code that needs to be modified:
========== Modify code below ==========
========== Modify code above ==========
Swipe to start coding
You have implemented the login() function, which raises errors. Implement the safely_auth() function that uses the login() function and catches errors.
- Create a code block to track errors (mention the keyword).
 - Call the 
login()function in the error tracking block. - Catch the 
TypeErrorand save its info inside theerrorvariable. - Print the 
errorvariable (error info) in the console. - Catch the 
ValueErrorand save its info inside theerrorvariable. 
Oplossing
Bedankt voor je feedback!
single