+ 1
How to create n number of instances of a class in python... ?
•I need my user to decide how many instances he needs •If the user enters 5 I need to create 5 instances of the class where the user provides the data. https://code.sololearn.com/ctrP1ekc5Brz/?ref=app
1 Respuesta
+ 1
Thank you for your kind response sir . I solved the issue . All my concepts were correct but i made a mistake .
•I just skipped the statement of appending 0's
•As I tried to assign values to empty list using index values -- The compiler said list index out of range .
•I thought that i could not process an object as a data in the list . So it pops some random error.
•I learnt this today.