Question: Type in the code below to display a menu system and perform a task. Create a function called do _ something that simply displays what
Type in the code below to display a menu system and perform a task. Create a function called
dosomething that simply displays what was done. Be sure to build in an error checking mechanism
that warns the user of an invalid choice. Hint: your function will incorporate an IF test to determine
what is output. points
def main:
printmenu
choice intinputPlease enter choice:
dosomethingchoice #function call
def printmenu:
print Create username"
print Delete user"
print Change address"
print Exit program"
main
Sample output:
A username was created
A user was deleted
An address was changed
Exit
Please enter choice:
A user was deleted
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
