I have a list of .csvs - They have been named in a very uniform fashion, say, BMW_year i.e. BMW_60, BMW_61 ... BMW_70 ... BMW_00.. and so on. I want to pull them into a pandas dataframe - which I can do using a pd.read_csv(..) function.
But there are many .csvs and I was hoping to do something more on the lines of -
for i in range(70, 80):
BMW_{i} = pd.read_csv(BMW_{i}.csv)
where {i}
will be like a reference to whatever the value of i is during that iteration of the loop. Is there a way I can achieve this?
P.S. I saw a lot of questions on dynamic naming and people saying - use lists or dictionaries but I don't think thats what I am asking for, in this question.