程序代码:

age = input("How old are you? ")
height = input("How tall are you? ")
weight = input("How much do you weigh? ")

print(f"So, you're {age} old, {height} tall and {weight} heavy.")

输出结果:

How old are you? 35
How tall are you? 173
How much do you weigh? 80kg
So, you're 35 old, 173 tall and 80kg heavy.
最后修改:2021 年 03 月 09 日
如果觉得我的文章对你有用,请随意赞赏