with open('D:\photo\links.text', 'r') as file:
for n in range(1, 1000):
url = file.read().splitlines()[f'{n}']
TypeError Traceback (most recent call last)
Cell In [99], line 3
1 with open('D:\photo\links.text', 'r') as file:
2 for n in range(1, 1000):
----> 3 url = file.read().splitlines()[f'{n}']
TypeError: list indices must be integers or slices, not str