Guest List Checker
Python
15 pts
Guest List Checker
Use membership and identity operators to create three booleans:
invited—Truewhenvisitoris in the listguests.has_z—Truewhen the letter"z"is in the stringvisitor.no_phone—TruewhenphoneisNone(useis).
Print them in that order. Expected output:
True False True
Checklist
- Keep the given values and create
invited: whethervisitoris inguests. - Create
has_z: whether the letter"z"is invisitor. - Create
no_phone: whetherphoneisNone, usingis. - Print the three booleans, one per line.
🔑 Solution
If you view the solution before passing, you earn half points for this exercise. You still need to type it and press Check to finish.
How it works, step by step
Point at a step to highlight its lines. Type the solution yourself and press Check answer to finish.
