Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

To obtain marks for the below exercises, do not use any Python built-in functions that are not in the lecture slides or class notes (such

To obtain marks for the below exercises, do not use any Python built-in functions that are not in the lecture slides or class notes (such as index or count). Instead, write your own control structures. The only built-in functions you are allowed to use are ones we learned in class such as append, len, range, print, and input.

image text in transcribed

4) Write a program that initializes the below list of numbers myList. Your program will then compute the cube of each value in myList, will store each cube in a new list such that the list of cubes is the reverse order of the numbers in myList. Your program will then print out the new list of cubes. The list of numbers myList can be initialized as the following: myList = [1,2,3,4,5] Sample run: The cubes of the numbers are: [125, 64, 27, 8, 1]

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

Database Design And Implementation

Authors: Shouhong Wang, Hai Wang

1st Edition

1612330150, 978-1612330150

More Books

Students also viewed these Databases questions

Question

Understand how environmental scanning is practised.

Answered: 1 week ago

Question

Write down the Limitation of Beer - Lamberts law?

Answered: 1 week ago

Question

Discuss the Hawthorne experiments in detail

Answered: 1 week ago

Question

Explain the characteristics of a good system of control

Answered: 1 week ago

Question

State the importance of control

Answered: 1 week ago

Question

What were the issues and solutions proposed by each team?

Answered: 1 week ago