📜  自我python代码示例

📅  最后修改于: 2022-03-11 14:45:44.256000             🧑  作者: Mango

代码示例2
class Person:
  def __init__(mysillyobject, name, age):
    mysillyobject.name = name
    mysillyobject.age = age

  def myfunc(abc):
    print("Hello my name is " + abc.name)

p1 = Person("John", 36)
p1.myfunc()