Terrapin Resources

Logo Blocks Tutorial — Beginner Mode

View and download a PDF of this tutorial.

A popular way to learn to code is to use blocks. Each block contains an instruction. You can combine blocks to make larger programs.

Terrapin Logo offers blocks! What makes Logo Blocks different from other block coding apps is that code for the Logo programming language is automatically generated when you put blocks together.

To start exploring, go to https://logoblocks.terrapinlogo.com Enter the code you received when you signed up for this free app.

When you first start Logo Blocks, you will see the Beginner set of blocks. After you learn how to use blocks, you can switch to the Advanced set of blocks, which gives you access to a broad range of commands.

Let’s see how block coding works! We’ll start in Beginner mode.

Move and Turn the Turtle

In Beginner mode, use the blocks in the first two rows to move the turtle forward and back.

The first three blocks in each row move the turtle a specific distance: 10, 50, or 100 steps.

Drag the forward 100 block into the command area to the right of the blocks.

Then, click the green arrow to run the code.

If you look at the Editor, you will see that Logo added the code for the button you added. This is the code that Logo will be running.

Logo adds a command to slow the turtle down in Beginner mode. That lets you watch how it moves.

The Forward and Back blocks with the number 100 are for a variable distance. You can change the number 100 to any value you choose, after you drag it to the command area.

Each time you click the Run button, Logo follows your commands. To erase your block, drag it to the Trash can at the bottom of the command area. Doing that also erases your code in the Editor and your picture in the Graphics area.


The next two rows of blocks are for turns.

You can turn 45 degrees, 90 degrees, 135, or 180 degrees to the right or left. You can change 180 to any number you choose if you want a different angle. Use the mouse to select the angle you want.

Quick Tip:

At the bottom of the Graphics panel are two buttons.  

  • Click Save to keep your picture. Give it a name and click OK. The file goes to your Downloads folder.
  • Click the Reset button to erase your drawing. There is no warning, so be sure you really want to erase your picture!

Control How the Turtle Draws

The next row of blocks lets you control the drawing.

Use the Erase block to clear the drawing. Put it the beginning of your code to erase any lines that are already in the Graphics panel. The Logo command is CS, short for Clearscreen.

Use the Pen Down block to lower the turtle’s pen so it can draw a line.

Use the Pen Up block to raise the turtle’s pen so it can’t draw.

Here is what your block code might look like, what the turtle draws, and what is recorded in the Editor.

Create Loops

The last block in the Beginner section lets you create loops! Logo calls this a REPEAT command.

You can change the 1 to any number from 1 to 10. Just click the arrow pointing down after the number 1.

After the word Do: is a place to put a block. You can drag a forward block after Do: to include it in the Repeat block. You can then add another block to be repeated.

What do you think this code will draw? Compare the block code to what is in the Editor.

The turtle will move forward 100 steps, and then turn right. It will do that 4 times.

Do you see the design in the Graphics area? Now you know how to draw a square!

How could you change the square? Can you make it larger or smaller? Can you add a block to erase the drawing before it runs the program?

Edit Your Code

To edit a block program, you can drag blocks to disconnect them. Drag the Forward 100 block in the Repeat loop out of that block. Now, drag the Right 90 block down to separate it from the Forward 100 block.

Now you can move either (or both) of those commands to the Trash can.

Replace the Forward 100 block with a different block. Try adding the variable Forward command and set the number of steps to 200. Click in the box with 200 and type a different number.

This code erases the screen, turns the turtle 45 degrees to the right and then draws a larger square.

Here are the results:

Play around with different turns and distances.

Pay attention to the Editor. Every time you make a change to the blocks, the code in the Editor changes to match it.

Did you know that you can nest repeats? That means you can put one inside the other.

Try this!

Save and Load Your Code

To save your Logo Blocks program, click the Save button at the bottom of the blocks area.

Type a name for your file that describes what you did. When you click the OK button, the file is saved to the Downloads folder in your computer.

To get a saved program back, click the Load button. Saved programs go to your Downloads folder, so you may find it there. But you may have moved the file to a different location. If you need to search for the program, remember that its file name ends with .xml.

Note that the Save button in the Editor saves just the Logo commands that are in the Editor. If you do this, you can use the code later in the full Logo programming language.

Although you could use your browser’s Print option to print your entire screen, you probably won’t like the results. The text and graphics will be too small! A better option is to use your computer’s PrintScreen function. You can select the area you want to capture. This action will copy the area you choose to the Clipboard. You can then paste it into another application to print it. Refer to your computer’s Help for details.

Quit Logo Blocks

To exit Logo Blocks, click the red Quit button.

You can click Yes to log out or No to stay in Logo Blocks.

Don’t forget to save your work before you leave!