34 out of 36 users completed this Bite ...
Will you be Pythonista #35 to crack this Bite?
Average Bite difficulty 1-10 rating: 4.67
» Up for a challenge? 💪
Create a function that takes a username and checks for a valid user:
- The username is in
- the user is not expired, and
- the user has the
If those 3 conditions are met return
If one of the conditions is not
Trueraise an exception you define yourself:
UserNoPermissionrespectively. Check out the tests for more detail.
Have fun and keep calm and code in Python!