I'm looking for a way to add the nested list elements to a dictionary. My current approach only adds the last list element to the dictionary. Any help would be very much appreciated!
list = [['710.09', '65.09', '2.0'], ['710.09', '65.09', '3.0']]
categories = {'rent': None, 'size': None, 'rooms': None}
for element in list:
list=dict(zip(categories, element))
output: {'rent': 710.09, 'size': 65.09, 'rooms': 3.0}
desired output: {1:{'rent': 710.09, 'size': 65.09, 'rooms': 2.0},2:{'rent': 710.09, 'size': 65.09, 'rooms': 3.0}}