Skip to content

Commit 8285f6f

Browse files
Update README.md
1 parent 7b388f9 commit 8285f6f

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,11 @@
33
写着玩儿的(<br>
44
增加了像String和Integer这样的类,是对Python原版类型的扩展<br>
55
例如,你可以用这个模块的String类来创建字符串,这样你就可以使用这个类的函数,例如isNumber()函数,可以判断这个字符串是否是由数字组成的<br>
6+
'''Python
7+
from type import *
8+
test = String("Hello World")
9+
print(test) # Hello World
10+
print(test.isnumber()) # False
11+
print(test.length) # 11
12+
'''
613
你同样可以重写这些类,来为它们添加更多方法<br>

0 commit comments

Comments
 (0)