We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2fc0ee2 commit e15dd0aCopy full SHA for e15dd0a
com/lxl/test/Sln_Demo.py
@@ -1,6 +1,40 @@
1
import keyword as kw
2
3
-print(kw.kwlist)
4
-#
+# print(kw.kwlist)
+
5
6
+class Person:
7
8
+ name = ''
9
+ age = ''
10
11
+ def __init__(self):
12
+ self.name='张三'
13
+ self.age='10'
14
15
+ def __init__ (self,nameParam,ageParam):
16
+ self.name=nameParam
17
+ self.age=ageParam
18
19
+ def speak(self):
20
+ return "姓名是:"+self.name+";"+"年龄是:"+self.age
21
22
23
+if __name__ == '__main__':
24
25
+ # p1 = Person()
26
+ # p1.age='18'
27
+ # p1.name='bruce'
28
+ # print(p1.speak())
29
+ p2 = Person('李四','20')
30
+ print(p2.speak())
31
32
33
34
35
36
37
38
39
40
0 commit comments