flâneur — a map of the web's best reading

Learn Lua in Y Minutes

learnxinyminutes.com · 2,320 words · saved by 1 readers

I started with BlackBulletIV's Lua for programmers. Next I read the official Programming in Lua book. That's the how. It might be helpful to check out the Lua short reference on lua-users.org. The main topics not covered are standard libraries: By the way, the entire file is valid Lua; save it as learn.lua and run it with "lua learn.lua" ! This was first written for tylerneylon.com, and is also available as a GitHub gist. Have fun with Lua! Got a suggestion? A correction, perhaps? Open an Issue on the GitHub Repo, or make a pull request yourself! Originally contributed by Tyler Neylon, and updated by 9 contributors. © 2025 Tyler Neylon

Learn Lua in Y Minutes Learn X in Y minutes Where X=Lua Language: English Deutsch español français italiano 한국어 português (Brasil) русский 中文 (简体) Get the code: learnlua.lua -- Two dashes start a one-line comment. --[[ Adding two ['s and ]'s makes it a multi-line comment. --]] ---------------------------------------------------- -- 1. Variables and flow control. ---------------------------------------------------- num = 42 -- Numbers can be integer or floating point. s = 'walternate' -- Immutable strings like Python. t = "double-quotes are also fine" u = [[ Double brackets start and end multi-

Explore this link on the map →

saved by

related reading