You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
9 lines
141 B
9 lines
141 B
class A:
|
|
def __init__(self, x):
|
|
self.x = x
|
|
self.y = 0
|
|
|
|
def get(self):
|
|
return self.x + self.y
|
|
A(1)
|
|
A(2).get()
|
|
|