笨办法学python习题7 更多打印
程序员文章站
2022-06-15 18:41:30
...
这个习题比较简单,设计到字符串的相加和相乘!话不多说,直接上代码:
print("Mary had a little lamb")
print("Its fleece was white as %s." %'snow')
print("And everwhere that Mary went.")
print("."*10)
end1 = "C"
end2 = "h"
end3 = "e"*2
end4 = "s"
end5 = "e"
print(end1+end2+end3+end4+end5)
运行结果:
mystuff simengred$ python ex7.py
Mary had a little lamb
Its fleece was white as snow.
And everwhere that Mary went.
..........
Cheese
上一篇: React(二):类组件、函数式组件
下一篇: react 函数组件和类组件的区别
推荐阅读
-
Python-打印指定范围内的全部回文素数(高教社,《Python编程基础及应用》习题8-7) (10分) 回文素数是指一个数既是素数又是回文数,例如131既是素数又是回文数。
-
笨办法学Python - 习题6-7: Strings and Text & More Printing
-
Python学习笔记(笨方法学Python3)-习题7:更多打印
-
笨方法学Python 习题 7: 更多打印
-
笨方法学python笔记:习题7 更多打印
-
笨方法学习Python-习题7:更多打印
-
《笨办法学 python3》系列练习计划——7. 更多打印
-
笨办法学Python 3 习题7
-
Python-练习 7 更多打印
-
笨方法学python练习7.更多打印