'导入turtle库' import time from turtle import * setup(600, 600, 807, 117) bgcolor('#08203D') '定义无痕画笔函数' def my_goto(x, y): penup() goto(x, y) pendown() '定义坐标轴函数' def coords_axis(): pencolor('LightGrey') pensize(2) speed(10) my_goto(-300, 0) fd(600) lt(90) my_goto(0, -300) fd(600) rt(90) my_goto(0, 0) '定义参考线函数' def ref_line(): pencolor('Grey') pensize(1) speed(0) row_y = 300 for i in range(int(600 / 100 - 1)): row_y -= 100 my_goto(-300, row_y) fd(600) lt(90) column_x = -300 for i in range(int(600 / 100 - 1)): column_x += 100 my_goto(column_x, -300) fd(600) rt(90) def TaiChi(): speed(10) color('black') begin_fill() circle(240, 180) end_fill() color('white') begin_fill() circle(240, 180) end_fill() color('b
python画太极图
于 2023-08-25 11:53:43 首次发布