交互式

>>> name = input("name:")
name:zhou
>>> print("{}student,learn Python,furture!".format(name))
zhoustudent,learn Python,furture!
>>> print("{}daxia,xuehaoPython,dazhanquanjiao! ".format(name[0]))
zdaxia,xuehaoPython,dazhanquanjiao! 
>>> print("{}大侠,学好Python,嘻嘻哈哈! ".format(name[1:1]))
大侠,学好Python,嘻嘻哈哈! 
>>> 

 

posted @ 2017-09-07 11:37  ELsky  阅读(214)  评论(0编辑  收藏  举报