2021-01-31

How to remove ' from a list with several items

Here is the code

(([(''+ 'e[' + str(i) + ']') for i in range(4)]))

Output :['e[0]', 'e[1]', 'e[2]', 'e[3]', 'e[4]']

I would like it to change to give me the following intended output: [e[0], e[1], e[2], e[3], e[4], e[5], e[6], e[7], e[8], e[9], e[10]]



from Recent Questions - Stack Overflow https://ift.tt/3pADQ8f
https://ift.tt/eA8V8J

No comments:

Post a Comment