- 博客(1)
- 收藏
- 关注
原创 绘制谢尔宾斯基三角形
import turtle import math turtle.speed(100) ''' 通过连接 3 个点的方式绘制三角形 pos是元组的元组((x1,y1),(x2,y2),(x3,y3)) ''' def draw\_triangle(pos): turtle.penup() # 移到第一个点 turtle.goto(pos[0]) turtle.pendown() # 连接 3 个点 for i in [1, ...
2022-06-18 10:32:00
597
2
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人