This page collects together useful reference materials and examples. If you have ideas for other good material for this page, post them on the discussion group so that they can make their way into this area. Pencil Code is free to use, but there are some community guidelines. Check out the terms of service and privacy policy, and take a look at the overview video.

Many printable classroom materials are gathered on activity.pencilcode.net. Here is a Quick Reference Sheet summarizing Pencil Code functions, and here is a brief CoffeeScript Language Reference. When learning about angles and turtle graphics, print out these reference sheets on Measuring Distance and Angles and on Arcs and Circles.

This Learn to Program with CoffeeScript tutorial introduces the basic concepts of Iced CoffeeScript by working on a single project. At the end of the two-hour tutorial, you have built a hangman game that uses variables, computer arithmetic, looping and conditionals, graphics, synchronization, and networking.

For teachers using Pencil Code to provide a elements of a full introduction to programming, the Pencil Code Teaching Manual provides twelve chapters of examples, explanations, and sample lesson plans on how Pencil Code can be used to cover topics from I/O, to Netsted Loops, to Recursion, to jQuery. The manual is freely available as printable PDFs.

There are many other resources for learning about CoffeeScript. The book Smooth Coffeescript by E. Hoigaard is a good book oriented towards new programmers. If you would like a video lecture, here here is a video course from Code School that is oriented towards students who already know some programming. The O'Reilly book Little Book on CoffeeeScript by Alex MacCaw is a svelte 62 pages. This slide deck from Aseem Kishore covers the language pretty thoroughly. If you are looking for a cookbook with ideas for small pieces of code, take a look at the CoffeeScript Cookbook online, or explore the examples below.

The examples below are fit for brief explorations. A
paperback guide
that includes color illustrations for each example is
available on Amazon or as a pdf.

- Lines. Programming with sequences and lines and curves. First Video, Worksheet. Angles video.
- Points. Dots, labels, variables and basic debugging techniques.
- Loops.
Using the
`for`

statement to repeat code. - Nesting. Nesting loops to build beautiful effects.
- Functions.
Using
`->`

to define your own functions. - Parameters. More powerful uses of function parameters.
- Time.
Repeating code using a simple
`tick`

timer. - Output.
Using
`write`

and HTML and CSS for output. - Input.
Using
`read`

and`button`

for input. - Numbers. How to use numbers for counting and calculation.
- Computation. Examples of more complex mathematical computations.
- Objects. Making and using objects with several properties.
- Arrays. Arrays are for sequences and vectors and stacks.
- Recursion. Recursive functions call themselves and can make amazing effects.
- Concurrency. Race conditions, shared memory, message passing.
- Sets. Multiple turtles and jQuery sets.
- Motion. Simulating motion with velocity, gravity, and physics.
- Networking. Using resources on the web.
- Intelligence. Artificial intelligence, reasoning, and backtracking.

(Check back soon: more to come.)