方式一 % 方式二 format() 方式三 f 示例 name = 'Mike' age = 22 print(f'我的名字是{name}\n我的年龄是{age}') 运行结果 我的名字是Mike 我的年龄是22