摘要:
用python计算圆周率并用进度条提示算的进度 一、蒙特卡罗法计算pi #e6.1CalPi.py from random import random from math import sqrt import time DARTS = 10**7 hits = 0.0 a=1 start = tim 阅读全文
摘要:
1、画五角星 import turtle turtle.pensize(5) turtle.pencolor("yellow") turtle.fillcolor("red") turtle.begin_fill() for i in range(5): turtle.forward(200) tu 阅读全文
摘要:
1、使用turtle库绘制一个红色五角星图形 import turtle turtle.pencolor('black') turtle.fillcolor("red") turtle.begin_fill() for i in range(5): turtle.forward(100) turtl 阅读全文