Question: [Using Python] Write a program that firstly creates a list and initializes it with the following numbers: 11, -22, 33, -44, 55, -66 Then, use

[Using Python]

Write a program that firstly creates a list and initializes it with the following numbers: 11, -22, 33, -44, 55, -66 Then, use a for loop to find out all elements with a negative numeric value, and change the values of those elements to their respective index numbers. Finally, print out the modified list.

[Using Python] Write a program that firstly creates a list and initializes

The original list is [11,22,33,44,55,66] The modified list is [11,1,33,3,55,5]

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!