Python 格式化输出字符串

字符串输出

print('hello world')

 

name = 'tom'

print('我的名字是%s' % name)

print(f'我的名字是{name}')

posted @ 2020-06-19 14:30  LIjunqiang  阅读(118)  评论(0)    收藏  举报