0
If i define class car then how to put methods to the user to assign object in that class?
3 Answers
+ 1
prop = input("Input a value: ")
car = Car(prop)
In Car class:
def __init__(self, prop):
0
Could you describe what you mean by "put methods to the user"?
My guess right now is to say that if your class is Car, make an object like so:
car = Car()
0
it should ask the user to assign the value to the objects