Python利用turtle庫畫虛線

Python利用turtle庫畫虛線 import turtle as t#給予turtle庫一個t的別稱 #t.setup(600,600,200,100) t.speed(0)#說明速度 t.pencolor(「red」)#說明顏色 for i in range(5):#用for循環遍歷 t.forward(20)#根據正前方角度畫線 t.penup()#畫筆擡起 t.forward(20)#
相關文章
相關標籤/搜索