Question: In Python, using the code below and abs() function, edit the program to replace any negative numbers in the list with positive ones. Expected result:

In Python, using the code below and abs() function, edit the program to replace any negative numbers in the list with positive ones. Expected result: 8,20,10,0,55, 777

original = [8,20,-10,55,-777]

for i in range (len(original)):

print(original[i])

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!