摘要: # name='egon' #name=str('egon')# print(type(name))#优先掌握# 移除空白strip# msg=' hello '# print(msg)# print(msg.strip())# msg='***hello*********'# msg=msg.st 阅读全文
posted @ 2017-07-19 17:31 Cool· 阅读(167) 评论(0) 推荐(0) 编辑
摘要: # >part1:数字类型#掌握:int,float#了解:Long(在python2中才有),complex# num=10# num=int(10)# print(type(num),num)# salary=12.5# salary=float(12.5)# print(type(salary 阅读全文
posted @ 2017-07-19 16:37 Cool· 阅读(221) 评论(0) 推荐(0) 编辑
摘要: #coding:utf-8 #utf-8格式打开#%s %d# name='egon'# age=18# print('my name is',name)# print('my name is my age is',name,age)#%s既能接收字符串,也能接收数字# print('my name 阅读全文
posted @ 2017-07-19 16:07 Cool· 阅读(531) 评论(0) 推荐(0) 编辑