Answered step by step
Verified Expert Solution
Question
1 Approved Answer
3 . 2 0 LAB: List basics Instructor note: Reminders: to create a list: the _ list = [ one , two, three ] to
LAB: List basics
Instructor note:
Reminders:
to create a list: thelist one two, three
to combine concatenate lists: onelist two list
to add thing to a list: the list. append thing
to find the position index of thing in a list: thelist. index thing
to assign something to an index of a sequence string or list: thelist index thing
to remove an element from a list: the list.remove thing
to remove an element from a list and assign it to a variable: result thelist.pop index
Given the user inputs, complete a program that does the following tasks:
Define a list, mylist, containing the user inputs: myflower myflower and myflower in the same order.
Define a list, yourlist, containing the user inputs, yourflower and yourflower in the same order.
Define a list, ourlist, by concatenating mylist and yourlist.
Append the user input, theirflower, to the end of our list
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started