Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

how do i make a system which asks user to enter number of operations it wanna perform. and for each operation entered perform one of

how do i make a system which asks user to enter number of operations it wanna perform. and for each operation entered perform one of the operations such as remove name, add name or max length name.
i tried to do it and this is what i have so far plz let me know what i am doing wrong.
image text in transcribed
so like this is how i wnat my output to be (Everything in between "" is the input entered by user) :
How many operations would u like to peeform? (add, remove, max) "3"
Enter an operation: "add Maniac"
Maniac added
Enter an operation: "remove Sana"
Sana removed
Enter an operation: "max"
Max name in list is Zenish
steps = int(input("How many steps do you want to perform?")), names = [] for step in range(steps): names.append(str(input("Enter the command")>> for command in names: for add in command.split(): if 'add' in add: print(command) for commands in names: for remove in commands.split(): if 'remove' in remove: print(commands)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle9i Database Administrator Implementation And Administration

Authors: Carol McCullough-Dieter

1st Edition

0619159006, 978-0619159009

More Books

Students also viewed these Databases questions