There is a task like this:
I have a list:
a = ["1", "2"]
And the for loop:
for i in range(0, 2):
print(a[i])
But if the list is with one element:
a = ["1"]
then there will be an error: IndexError: list index out of range
What can be done to keep the structure
for i in range(0, 2):