Course VVLogo A - Lesson 1

Overview

This lesson introduces students to VVLogo, and to the general notion of programming as a sequence of instructions for the computer to follow.

The VVLogo commands introduced in this lesson are FORWARD, BACK, RIGHT, and LEFT, along with their abbreviations FD, BK, RT, and LT.

Introductory

Warm up the class with some questions they will enjoy answering.

Who has a computer before?
Who has a computer at home?
Who has used the World Wide Web?
What web sites do you like to go to?

Tell the class that people communicate with each other using language. Ask, who knows a language other than English? People also communicate with computers using special computer languages. The language we will be learning is called VVLogo. In VVLogo, there is a little turtle that moves around on the screen, following your commands. As the turtle moves, it draws a line, as if it is walking on a piece of paper and holding a pen down on the paper. It's not a real turtle, of course, it really a small green triangle.

Ask for a volunteer to play the turtle. He or she should stand in front of the class. The turtle knows how to follow four commands which we'll talk about today. The student turtle should try to follow these commands.

The first command is FORWARD. Give the command "FORWARD 5" -- this means the student turtle should go forward 5 small steps. Another command is BACK. "BACK 3." "FORWARD 6." A third command is RIGHT. "RIGHT 90" -- this means turn right 90 degrees, and stay in exactly the same spot on the floor. (A short digression on degrees may be useful or necessary. Make sure the turtle, and the class, knows how to turn right 90, 180, and 360 degrees.) The last command is LEFT. "LEFT 90." "LEFT 90." "RIGHT 180." "LEFT 360."

With a second volunteer turtle, try this challenge. The teacher writes a short set of commands on the board, and the turtle follows them. Try "FORWARD 6 BACK 6." "FORWARD 5 RIGHT 90 FORWARD 5." "LEFT 90 BACK 2 RIGHT 180 FORWARD 4."

The commands each have an abbreviation you can use: FORWARD, FD; BACK, BK; RIGHT, RT; LEFT, LT.

Two more things the students have to know before starting the lab. First, VVLogo programs start with "HOWTO Draw" and end with "END" . We'll talk about this more next time. Make sure "HOWTO" is one word. Second, when students go to the web page, they will see two windows. One window is for entering commands; it has a button labeled Draw. Pressing this button makes the turtle follow the commands. The "output window" is where the turtle lives and draws line.

Programming Lab

The first step in all labs is to log on to the computer, start a web browser, and go to http://vvlogo.csed.org. If students work in pairs, two to a computer, they should take turns at the keyboard after every step. It's often best to have the regular teacher decide which students should sit next to each other, or partner with each other. Commentary for the teacher follows some lab steps in italics.
  1. VVLogo program Type this program in the program window:
    HOWTO Draw
      Forward 50
      Right 90
      Forward 50
    END
    
    and press the Draw button. You should see the turtle draw a line in the output window.

  2. Change the program you wrote in step 1 so that it uses the abbreviations FD for Forward and RT for Right. Run it again. Try some different numbers besides 50 and 90.
    VVLogo allows numbers between -10000 and 10000 (with no comma separating the thousands).

  3. How far is the turtle from the top edge of the output window? Write this program:
    HOWTO Draw
      FD ?
    END
    
    but instead of ? find a number that moves the turtle just up to the edge of the white area. You'll have to experiment a little. Write your number here: ____________

  4. Write another series of instructions for the turtle, between HOWTO Draw and END, that teach the turtle how to explore all four corners of the window. You can use Forward (FD), Backward (BK), Right (RT), and Left (LT). When you press the Draw button, the output window should look something like this:
    VVLogo output

Concluding Questions and Answers

Ask students to help you teach the turtle to draw a capital L. Two possible programs are
HOWTO Draw
  BK 40
  LT 90
  BK 20
END
and
HOWTO Draw
  RT 90
  FD 20
  BK 20
  LT 90
  FD 40
END

Evaluation Activity

  1. Write a short program on the board, and have the students "play turtle" and draw the result on a sheet of paper. Here's a possibility, which draws a Y:
    HOWTO Draw
      FD 50
      RT 45
      FD 25
      BK 25
      LT 90
      FD 25
    END
    
  2. Write a shape or design on the board, and have the students write the turtle commands that would produce it. Good choices are a square and a capitol T.