Meet Gray

A programming course for kids that teaches real code, one line at a time โ€” right in the terminal, in Python or Lua.

โ–ถ Play in your browser Python setup Lua setup โฌ‡ Downloads

Free & open. One file. No accounts needed and no ads.

 Terminal โ€” python gray.py
$ python gray.py Welcome to Gray! ๐Ÿ˜ Let's learn Python. First secret: your computer is a GIANT calculator. Try it! Type: 2 + 2 and press Enter. you> 2 + 2 = 4 โญ Perfect! You just wrote your first Python script! ๐ŸŽ‰
 

programmers started their journey with Gray

Why kids (and parents) love Gray

Gray is a friendly guide that lives in one file. It explains an idea, the student types real code, and Gray runs it, checks it, and cheers.

โŒจ๏ธ

Real code from minute one

No toy blocks. Kids type genuine Python or Lua โ€” the exact same code professionals write โ€” and see it run instantly.

๐Ÿ—บ๏ธ

11 guided sections

From โ€œyour computer is a giant calculatorโ€ to variables, decisions, loops, input and functions โ€” each idea builds on the last.

๐Ÿ”ฎ

3 real projects

Kids build a mind-reading number game, a silly story machine, and a robot doorkeeper โ€” programs they can proudly demo to the family.

๐Ÿ’ก

Hints, not punishments

Wrong answers get a gentle nudge and another try. Stuck? Type hint. Every solved challenge earns a โญ.

๐Ÿ’พ

Progress is saved

Type quit anytime โ€” Gray remembers exactly where the student left off and picks up there next time.

๐Ÿ›Ÿ

Safe to explore

Kids can experiment freely. Even a loop that never ends gets rescued โ€” Gray plays lifeguard and stops it with a smile.

๐ŸŽ“

Graduates into the real world

In the final section the student builds their own script file, runs it with python my_first_program.py, and discovers the real REPL.

๐Ÿชถ

Nothing to set up

Gray is a single file with zero dependencies. If Python or Lua runs on the computer, Gray runs. Fully offline.

Two languages, one course

The same adventure exists in Python and Lua. Finish one track, then see how the other language says the same things!

The adventure map

Eleven sections, each one unlocking a new superpower.

IntroductionThe computer as a giant calculator, and making it talk with print.
Variables โ€” give things a nameBoxes with name stickers: remember numbers and words, glue words together.
If this, then thatYes/no questions, True and False, and a secret-club password door.
Loops โ€” do it again!Cheer five times with one line, print times tables, roll dice. ๐ŸŽฒ
Input โ€” the computer asks YOUPrograms that listen, ask questions, and turn answers into numbers.
While โ€” the loop with a brainA rocket countdown that stops itself, and the magic doubling coin.
Functions โ€” teach it new wordsThe computer doesn't know cheer()โ€ฆ until your kid teaches it.
Project: The Number Wizard ๐Ÿ”ฎBuild a real guessing game with a hidden random secret.
Project: The Silly Story Machine ๐Ÿ“–A mad-libs machine โ€” a brand-new ridiculous story every run.
Project: The Club Doorkeeper ๐Ÿค–The capstone: a robot that greets, guards, and throws a party.
Graduation โ€” programs of your own ๐ŸŽ“Build a real script file line by line, run it yourself, meet the REPL.

The adventure continues ๐Ÿ—บ๏ธ

Finished Foundations? Paid paths take the same seven superpowers and build real games with them โ€” entirely in the browser, nothing to install. One subscription unlocks every path, current and future. Foundations stays free forever.

๐ŸŽ’

Path: The Game Maker

Backpacks full of loot (lists), character sheets (dictionaries), treasure chests with random surprises, a crafting table of functions โ€” and the capstone build: The Elephant's Quest, a real adventure game with rooms to explore, a key to find, and a golden door to open.

Get started in 3 steps

Pick a track. Python is the world's most popular first language; Lua is small, friendly, and powers games like Roblox. You can't choose wrong โ€” the course is the same adventure in both. In a hurry? Play right in your browser โ€” nothing to install at all.

1Install Python

First check if it's already there. Open a terminal and type:

python3 --version

If you see something like Python 3.12.4, you're done โ€” skip to step 2! Otherwise:

macOS
  • Macs usually include Python 3 already (try the command above in the Terminal app).
  • If not, download the installer from python.org/downloads and run it.
๐ŸชŸ Windows
  • Download the installer from python.org/downloads.
  • Important: on the first installer screen, tick โ€œAdd python.exe to PATHโ€.
  • Then open Command Prompt and check with python --version.
๐Ÿง Linux
  • Almost always preinstalled. If not: sudo apt install python3 (Debian/Ubuntu) or your distro's equivalent.

2Download Gray

โฌ‡ Download gray.py

Save it somewhere easy to find, like a gray folder in your home directory. Or grab it from the terminal:

curl -O https://gray.academy/gray.py

3Start the adventure

In the terminal, go to the folder where you saved it and run:

python3 gray.py

(On Windows it's usually python gray.py.) Gray takes it from there โ€” say hi! ๐Ÿ˜

1Install Lua

First check if it's already there. Open a terminal and type:

lua -v

If you see something like Lua 5.4 (any 5.x works), you're done โ€” skip to step 2! Otherwise:

macOS
  • With Homebrew: brew install lua
  • No Homebrew? Install it first from brew.sh (one command), then run the line above.
๐ŸชŸ Windows
  • With winget (built into Windows 10/11): open PowerShell and run winget install DEVCOM.Lua
  • Or download prebuilt binaries from luabinaries.sourceforge.net and add the folder to your PATH.
๐Ÿง Linux
  • sudo apt install lua5.4 (Debian/Ubuntu) or your distro's equivalent. On some systems the command is then lua5.4 instead of lua.

2Download Gray

โฌ‡ Download gray.lua

Save it somewhere easy to find, like a gray folder in your home directory. Or grab it from the terminal:

curl -O https://gray.academy/gray.lua

3Start the adventure

In the terminal, go to the folder where you saved it and run:

lua gray.lua

Gray takes it from there โ€” say hi! ๐Ÿ˜

Downloads

The whole course is one file per language. That's it โ€” that's the download. Or skip downloading entirely and play in your browser.

gray.py

Python track ยท runs with Python 3

โฌ‡ Download
gray.lua

Lua track ยท runs with Lua 5.1+

โฌ‡ Download

Questions parents ask

Is Gray free?

The Foundations course โ€” all eleven sections, in the browser or downloaded โ€” is free forever, no strings. The optional subscription adds extra learning paths (like The Game Maker) that build on Foundations; those run in the browser only, with the same progress-saving, hints, and gentle nudges.

What age is Gray for?

Roughly 8โ€“13, or any curious beginner who can read and type. Younger kids do great with a grown-up sitting alongside for the first sections.

Which track should we pick โ€” Python or Lua?

Either! Python is the most common first language in schools and careers. Lua is lightweight and famous in game modding (Roblox uses a close cousin). The course content is the same adventure in both โ€” many kids finish one track and replay the other to compare.

What if they type something wrong?

Gray never scolds. Mistakes get a friendly explanation and another try, and typing hint reveals the answer shape. Even errors are framed as โ€œthat happens to every programmer.โ€

Can they stop midway?

Yes โ€” typing quit saves progress automatically. Next time Gray says โ€œwelcome backโ€ and continues exactly where they stopped. The menu command lets them revisit any finished section.

What do they have at the end?

Three working programs they built themselves, plus my_first_program.py (or .lua) โ€” a real script file assembled line by line during graduation, which they know how to run and edit on their own. In the browser version it can be run right on the page and downloaded to keep.