Lua
A tiny language designed to be embedded.
Lua is taught here in 3 lessons, running from Lua syntax and types through to Embedding Lua in a host program. Each lesson takes one topic, shows the working code, and links onward to the next, so the course can be read straight through in order.
| Track | Programming Languages |
| Lessons | 3 |
| Level | Beginner |
| Reading time | about 39 minutes |
| Prerequisites | Helpful, but not required: Scala |
Lessons
- Lua syntax and typesLocals versus globals, the eight value types, 1-based tables, and the operators that surprise newcomers.
- Tables, metatables and object orientationHow __index and __newindex turn plain tables into classes, proxies and read-only views.
- Embedding Lua in a host programThe C API stack, passing values in both directions, registering host functions, and sandboxing untrusted scripts.
More in Programming Languages
FAQ
How long does the Lua course take?
It has 3 lessons, about 39 minutes of reading. Expect roughly twice that if you type out and run every example.
Do I need prior experience for Lua?
Not strictly. It helps to have read Scala first, because some lessons build on it, but every lesson explains its own assumptions.
What should I read after Lua?
Continue with Dart (3 lessons), the next course in Programming Languages.
Last refreshed 2026-09-18.