Question: The above loop _ list a list - type variable which contain numbers that are string - typed ( ex . [ ' 1 '

The above loop_list a list-type variable which contain numbers that are string-typed (ex.['1','2','3','4','5'])
Create a program, loopindex.py. Your program should:
Convert these string-type integers into integer-type.
For each of the numbers in the list, add its own index position.
Example 1- If the argument is ['5','5','5'], the program should print:
[5,6,7]
Example 2- If the argument is ['4','11','0','0','1'], the program should print:
[4,12,2,3,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 Programming Questions!