Lightbot BasicProgramming PDF
Lightbot BasicProgramming PDF
Lightbot BasicProgramming PDF
!
!
!
!
Creating and Running a Program
!
Main Goal: Understand how to create and give a computer a set of
instructions to follow.
!
Overview Materials
Students play the initial set of “Basic” Lightbot game (on computer or iOS or
levels in Lightbot. They will learn how to Android device)
tell a computer what to do with a series !
of basic commands and gain the Whiteboard/chalkboard/projector
general process by which computer
programs are written.
Objectives Preparation
Students will learn how to Make sure that Lightbot runs on the
! selected device(s) before class starts:
1) Plan out a series of instructions !
2) Write a Program, and have Web
Lightbot run through the instructions Computers will need Flash Player
3) Test if the end result was correct (all installed when running the game at
the blue tiles were lit) light-bot.com/hocflash.html
4) Debug If the result was not correct, !
walk through what happened, find iOS or Android
the mistake, and modify the The Lightbot app should be pre
program installed on the class devices
!
Play the initial 3 levels following the in-
game instructions to understand how
students need to solve puzzles
!
!
!
!
!
Introduction
Computers are amazing things. They are these devices which enable us to do so many things:
play games, explore the internet, make art and create music. They’re exceptionally good at
doing really complex tasks, but they have to be programmed, or told, how to do those tasks
first.
!
Programming is how we, as programmers, can tell a computer what to do. A computer does
not understand regular English. We cannot simply program a computer by telling it to “walk the
dog” or “do my homework”. Computers understand only a small set of instructions. What our
job is, as programmers, is to tell the computer how to use the instructions it knows, to solve a
problem we have.
!
Exercise
Today, we are going to be playing a puzzle game called Lightbot. In Lightbot, there is a robot
and he lives in a world of square tiles. The goal in each level is for Lightbot to light up all the
blue tiles in the level. However, Lightbot does not understand something as complicated as
saying “light all the blue tiles”. Instead, he does understand a basic set of rules. Display the
following to students.
!
An arrow icon tells Lightbot to move forward one space.