For Kids and Beginners

Most programming languages are text-based. You type your code into the computer, and if you don't type everything correctly, the program doesn't work. Javascript is no different. If you put a comma in the wrong place, you get an error message if you are lucky, or worse, your program silently does the wrong thing.

We can ease the way for kids and beginners by using a block-based language, where you drag and drop icons onto the screen, and they fit together like puzzle pieces. All of the troublesome syntax is hidden. The computer quietly translates the block program into Javascript for you. You then have your choice: you can continue programming with blocks, or you can switch to editing the Javascript.

Block-based languages make small programs easy to create. Moving to text-based programming later has benefits when the program gets larger since you can use powerful text manipulation tools that don't exist for block-based languages.

There are many block-based languages. You may have heard of Scratch, which comes built-in on Raspberry Pi computers, or Blockly, the language we are going to discuss next.