with open("list.txt") as f:
lst = (f)
print(lst)
for h in lst:
print(lst[h])
In a loop i want to open a file take 1st line as a var and do something with selenium and then take another line and do the selenium stuff again until last line. trying since evening only getting errors. like list indices must be integers or slices, not str.