单选题
下面代码自定义了一个函数,实现以(100,50)为初始坐标,绘制边长为50的红色正方形,选项中正确调用函数的是()
import turtle as tdef draw_square(a,b,c,d,e):t.penup()t.goto(a,b)t.pendown()t.color(c)for i in range(e): t.forward(d) t.left(360 / e)
A.
draw_square(100,50,'red',50,4)
B.
draw_square(100,50,'red',50)
C.
draw_square(50,100,'red',50,4)
D.
draw_square()
发表评论 取消回复