1.在我们本身的电脑上找到python 的IDLE东西。
2.然后翻开IDLE,新建一个文件,命名为test1.py。
相干引荐:《python视频教程》
3.接着我们就最先导入turtle库,然后编辑代码。
from turtle import * penup() goto(0,-200) pendown() circle(200) penup() goto(-100,50) pendown() begin_fill() circle(17.5) end_fill() penup() goto(100,50) pendown() begin_fill() circle(17.5) end_fill() penup() goto(0,50) pendown() circle(-70,steps=3) penup() goto(-150,-70) pendown() right(15) goto(0,-170) goto(150,-70) hideturtle()
4.F5运转代码,检察效果图。
以上就是如何用python画笑容的细致内容,更多请关注ki4网别的相干文章!