Question: Question 4 . Create a list that describes a new fourth row of this table. The details can be whatever you want, but the list

Question 4.
Create a list that describes a new fourth row of this table. The details can be whatever you want, but the list must contain two values: the number of petals (an int value) and the name of the flower (a string). For example, your flower could be "pondweed"! (A flower with zero petals)
orchid
my_flower =[3, "orchid"]
my_flower
[3, 'orchid']
check('tests/q4.py')
All tests passed!
Question 5.
my_flower fits right in to the table from chapter 5. Complete the cell below to create a table of seven flowers that includes your flower as the fourth row followed by other_flowers. You can use with_row to create a new table with one extra row by passing a list of values and with_rows to create a table with multiple extra rows by passing a list of lists of values.
# Use the method .with_row(...) to create a new table that includes my_flower
four_flowers =
# Use the method .with_rows(...) to create a table that
# includes four_flowers followed by other_flowers
# Notice that other_flowers is a list of lists.
other_flowers =[[10, 'lavender'],[3, 'birds of paradise'],[6, 'tulip']]
seven_flowers =
seven_flowers

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!