"while relying on...." :P
Anyways...
Basically I am starting off with a user defined number of variables. For each object needed, I 'assign a variable'
by using the key of a dictionary. How do I use object references, append to list and what not, if i am relying on a dictionary to call it?
Anyways...
Basically I am starting off with a user defined number of variables. For each object needed, I 'assign a variable'
by using the key of a dictionary. How do I use object references, append to list and what not, if i am relying on a dictionary to call it?
Code:
dict = {1:['a','b','c','d'], 2:classObj1, 3:classObj2}
dict[1].append('e','f','g','h','i')
dict[2].classObj2Method()
dict[3].classObj3Method(2, myData)
print(dict[3].name)
Comment