Summary of commands in MSWLogo

November 2022 · 2 minute read

Summary of commands in MSWLogo, In this article, let's learn the commands included in MSWLogo, making programming with this software faster.

MSWLogo is an interpreted programming language, based on the Logo computer language platform, with a graphical user interface (GUI). It is free and open source programming software, with source code available in Borland C++.

Picture 1 of Summary of commands in MSWLogo

MSWLogo supports many turtle graphics, 3D computer graphics and allows input from COM and LPT ports. It also supports a windowing interface, so input/output (I/O) is available through this GUI and keyboard and mouse events can trigger interrupts.

In this article, let's learn the commands included in MSWLogo, making programming with this software faster.

Commands included in MSWLogo

CommandAbbreviationSyntaxOutputFor example
FORWARDfdFORWARDMove the turtle forward with the specified number of timesforward 100 or fd 100
BACKbkBACKMove the turtle backwards with the specified number of timesback 100 or bk 100
RIGHTrtRIGHTRotate the turtle to the right by the specified number of degreesright 228 or rt 228
LEFTltLEFTRotate the turtle left by the specified number of degreesleft 228 or lt 228
HOMEhomeHomeGo to the center of the screen but do not clear the screenhome
CLEANct csCleanClear the screen of the trail but keep the turtle positionclean
CLEARSCREENCSClearscreenClear the screen of the trail and go to the center of the screencs
HIDETURTLEHTHide turtleHide the turtle and support to see the drawing clearly on the screenht
SHOWTURTLESTShow turtleShow the turtle after it is hidden from the screenst
PENUPPU(set) Pen upSet the turtle to move without drawingpu
PENDOWNPD(resets) PenReset brush when prompted to movepd
CLEARTEXTCTClear textClear all text in command screenct
CIRCLE CircleCreate a loop
that repeats 360 [FD (desired length in pixels divided by 360) RT or LT 1]
circle
PatternpayPatternCreate a patternpattern

Commands to create some basic 2D drawings

Picture 2 of Summary of commands in MSWLogo

PictureCommand
SquareRepeat 4 [fd 200 rt 90]
RectangularFd 300 rt 90 fd 150 rt 90
Fd 300 rt 90 fd 150 rt 90
CircleRepeat 360 [fd 3 rt 1]
TriangleRepeat 3 [fd 300 rt 120]
The PentagonRepeat 5 [fd 200 rt 72]
HexagonRepeat 6 [fd 200 rt 60
OctagonRepeat 8 [fd 150 rt 45]
hexagon shapeRepeat 9 [fd 150 rt 40]
HexagonRepeat 10 [fd 100 rt 36]

ncG1vNJzZmismaXArq3KnmWcp51kwLa5zJqpsmWfm3qku8ymmKeco2K2r3nMrK6lp5ek