Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please show me step by step in python Task 3 - Using the same list from Task 1, do the following Change the first element

please show me step by step in python
image text in transcribed
Task 3 - Using the same list from Task 1, do the following Change the first element to 1.5 Add a new element 8.5 to the end of the list Insert the value 5.5 in between the existing elements 5 and 6 in the list Remove the existing element 10 . The list is now out-of-order, so sort it! Task 4 - Create a tuple, where the first element is your name, and the second element is your student ID - Create a tuple, by using the tuple(...) function to convert the list from the previous tasks - Print out a random element of the second tuple, by using the random module and random.randrange O function to choose a number between 0 and the length of the ruple - Write some code which will try to modify one of the tuples in some way (e.g., tries to change an existing element). This will cause the program to throw an error, and crash. When this happens, find the name of the error that occurs (something like "2?2?Error"). Remove the code causing the error, and just print the name of the error you founid

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

Oracle 10g SQL

Authors: Joan Casteel, Lannes Morris Murphy

1st Edition

141883629X, 9781418836290

More Books

Students also viewed these Databases questions

Question

3. Evaluate a Web-based training site.

Answered: 1 week ago