Jump to content

Logo (programming language)

From Simple English Wikipedia, the free encyclopedia
The article about graphical symbols is at Logo
A graphic created with Logo

Logo is a programming language that is easy to learn. It is used to teach students and children to program a computer. It was developed to process lists of words. It was like the language LISP.

In 1967, the first Logo ran on a mainframe computer, a machine called a teletype was used to type in and printout the results.[1] There was no screen.

In 1969, it was used to control a Floor Turtle. Commands were added to sent the turtle forward and backwards, and to turn the turtle to left or right. This turtle had pen with different colors. When it moved, it left a trail on the floor.

This was very useful. When a new version of Logo was developed to draw graphics on a screen, it used the same commands. This was called Turtle graphics.

There are 170 versions of Logo. Many of them are open source and free. There are three Logo textbooks that can be downloaded free. Logo is usually an interpreted language.

Examples

Hello World

Load the Logo program. Type the next line in the command box.

print [Hello World!]

The computer replies.

Hello World!

Example Showing Graphics and Functional Programming

A spiral drawn using recursion. Using the editor, type in this new definition.

to spiral :size
   if  :size > 30 [stop] ; a condition stop
   fd :size rt 15        ; many lines of action
   spiral :size *1.02    ; the tailend recursive call
end

Type this in the command box.

spiral 10

On the screen you will see.


Logo Programs

Online books

References

  1. http://logothings.wikispaces.com/ Early History Wikispace