Apr-20-2019, 09:50 PM
Your terminology is incorrect. You are trying to make a dictionary, not a library. And your values are the same (1), not your keys. Keys by definition are different. If they were all the same key.
How to fix this is not clear, because what you want is not clear. Do you want the stock names a keys with the numbers as values?
How to fix this is not clear, because what you want is not clear. Do you want the stock names a keys with the numbers as values?
mydata = {} for stock in x: mydata[stock[0]] = stock[1:]
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures