Python打印三角形九九乘法表代码
作者:NGY0627 时间:2021-11-16 03:27:15
正三角形九九乘法表
#正三角形九九乘法表
for i in range(1,10):
for j in range(1,i+1):
print(str(i)+"*"+str(j)+"="+str(i*j),end="\t")
print("\n")
实现效果如下图所示:
倒三角形九九乘法表
#倒三角形九九乘法表
for m in range(1,10):
for n in range(m,10):
#print("{}*{}={}".format(m, n, m*n), end=" ")
print(str(m)+"*"+str(n)+"="+str(m*n),end="\t")
print("\n")
实现效果如下图所示:
来源:https://blog.csdn.net/SUPERCATMAN/article/details/122218771
标签:python,九九乘法表
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Python爬取视频(其实是一篇福利)过程解析
2021-09-21 17:52:11
python创建学生成绩管理系统
2023-08-09 04:19:38
![](https://img.aspxhome.com/file/2023/9/62299_0s.jpg)
使用PHP获取当前url路径的函数以及服务器变量
2023-10-31 02:31:34
python opencv将图片转为灰度图的方法示例
2021-03-24 22:22:54
![](https://img.aspxhome.com/file/2023/2/95372_0s.jpg)
asp定时生成静态HTML的代码
2010-07-02 12:29:00
Python激活Anaconda环境变量的详细步骤
2023-01-02 18:45:20
![](https://img.aspxhome.com/file/2023/0/76870_0s.png)
Python selenium 自动化脚本打包成一个exe文件(推荐)
2023-01-13 02:37:39
![](https://img.aspxhome.com/file/2023/9/95339_0s.png)
Python中的数据对象持久化存储模块pickle的使用示例
2023-09-26 01:26:28
记录下两个正则表达式的使用
2009-11-30 12:56:00
Python中的字典及其使用方法
2022-03-22 13:31:49
![](https://img.aspxhome.com/file/2023/3/93673_0s.png)
Python matplotlib画图实例之绘制拥有彩条的图表
2023-01-26 02:06:25
![](https://img.aspxhome.com/file/2023/8/86268_0s.jpg)
python解决12306登录验证码的实现
2023-05-29 10:28:35
![](https://img.aspxhome.com/file/2023/1/75161_0s.jpg)
Python astype(np.float)函数使用方法解析
2021-02-23 17:28:16
![](https://img.aspxhome.com/file/2023/5/83905_0s.png)
和server XMLHTTP相关的几个函数
2008-09-21 13:56:00
python多个模块py文件的数据共享实例
2022-02-24 23:33:39
页面新开窗口的一点补充
2008-09-10 12:57:00
Python中的异常处理相关语句基础学习笔记
2021-10-18 00:54:50
Oracle中pivot函数图文实例详解
2023-07-12 22:13:49
![](https://img.aspxhome.com/file/2023/0/64450_0s.png)
快速解决SQL server 2005孤立用户问题
2009-01-04 14:02:00
Python编写单元测试代码实例
2022-11-02 12:27:09
![](https://img.aspxhome.com/file/2023/1/93991_0s.png)