Friday, September 27, 2019

CODE - repl -circles!


CIRCLES!

The same circle drawn 4 different ways

with Randomized colours and SPEED



--commands--

1.3. Summary of Turtle Methods


MethodParametersDescription
TurtleNoneCreates and returns a new turtle object
forwarddistanceMoves the turtle forward
backwarddistanceMoves the turle backward
rightangleTurns the turtle clockwise
leftangleTurns the turtle counter clockwise
penupNonePicks up the turtles tail
pendownNonePuts down the turtles tail
colorcolor nameChanges the color of the turtle’s tail
fillcolorcolor nameChanges the color of the turtle will use to fill a polygon
headingNoneReturns the current heading
positionNoneReturns the current position
xcorNoneReturn the current x coordinate
ycorNoneReturn the current y coordinate
gotox,yMove the turtle to position x,y
begin_fillNoneRemember the starting point for a filled polygon
end_fillNoneClose the polygon and fill with the current fill color
dotNoneLeave a dot at the current position
stampNoneLeaves an impression of a turtle shape at the current location
shapeshape nameShould be ‘arrow’, ‘classic’, ‘turtle’, ‘circle’ or ‘square’

No comments:

Post a Comment