5
Microsoft LOGO BASIC FUNCTIONS

Microsoft LOGO

Embed Size (px)

DESCRIPTION

A complete guide to Microsoft LOGO

Citation preview

Microsoft LOGOBASIC FUNCTIONS

Nzb PublicationsTABLE OF CONTENTSChapter 1: Basic Commands1-21-Forward Command2-Backward Command3-Left Command4-Right Command5-Pen up Command6-Pen down Command7-Pen Size Command8-Hide, Show, Clear Screen, EndChapter 2: Advanced Commands21-Repeat2-Pen erase3-Pen normal4-Floodcolor5-FillChapter 3: Shapes with Logo31-Circle2-Hexagon3-Square4-Pentagon

Chapter 1: Basic CommandsFDX:Move ForwardXPixelsExample:FD100BKX:Move BackwardXPixelsExample:BK100LTX:Rotate the Turtle X Degrees LeftExample: LT 45RTX:Rotate The TurtleXDegrees Right.Example:Rt45PU:Short For "Pen Up," It Lifts The "Pen" From The Screen So That Moving The Turtle Doesn't Draw A Line.Example:PuPD:Puts the Pen Down So That Moving the Turtle Draws A LineExample:pdPensize:Sets The Width Of The Pen ToNPixels. Note That It Is Necessary To Put In Two Numbers.Example:Setpensize:ST:Shows The Current Turtle.HT:Hides The Current Turtle.

End:Marks The End Of A Procedure And Is Required.Cs:An Abbreviation for Clear Screen, It Clears the Screen and Returns the Mouse to Its Home Position.

Chapter 2: Advanced CommandsRepeatRepeats The Actions Listed In TheInstruction ListAnNNumber Of Times.Examples:RepeatN[Fd 10 Lt 90 Square]OrRepeat:Numrepeat[Fd 10 Polygon :Angle :Sidelength]PeneraseSets The Pen To Down And Sets The Mode To Erase. When The Pen Is Moved, It Will Erase Whatever Is Under It. An Abbreviation IsPe.Example:PeneraseOrPePennormalSets The Pen Back To Normal Mode And Cancels Erase Mode.Example:PennormalFloodcolor[R G B]Sets The Flood ColorTo The Appropriate RGB (Red, Green, and Blue) Values, WhereR,G,AndBAre Numbers That Range From 0 To 255. (Non-integers Are Rounded.)Example:Setfloodcolor[255 0 255](Gives Magenta)FillFloods The Area Bounded By Lines With Whatever Color Was Specified In The Setfloodcolor Command.Example:Fill

Chapter 3: Shapes With Logo1-Circle:repeat 1 [circle 100]2-Hexagon:repeat 6 [fd 50 rt 60]3-Square:repeat 4 [fd 100 rt 90]4-Pentagon:repeat 5 [fd 150 rt 72]