Skip to content

Speed learn Lua with a comprehensive guide

License

Notifications You must be signed in to change notification settings

exoad/learnlua.lua

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

learnlua.lua

A great language to add for bindings with your C programs

Speed Learn Lua with a comprehensive guide.
This is more intuitive for a more experienced programmer

Created by exoad

My journey with Lua

Targetted for 5.2+. You are more than welcome to contribute with addendums for other versions of Lua that have different dialect on how something should be used.

Read the barebones version here
https://exoad.github.io/learnlua.lua/

Reading

Coding style is presented with a simple example followed by a commented explanation.

The de facto code is stamped in ./snippet.lua. This code is not usable and only for evaluation!

For example:

print() --[[
  The print() function is primitive Input/Output function in Lua.

  By running it with print() no arguments, nothing is printed.

  By running it with arguments like print("Hello World") -> Hello World will be printed to the STDOUT
]]

Each section is marked with a commented feature like so:

-------------------
--[[ SECTION A ]]--
-------------------

TODOs

  • Make a web version -> Port all code to a website based.
  • Make a beginner friendly learning style and still keep the more experience cheatsheet
  • Make a generalized Lua Cheatsheet

Always work in progress (for improvements) :)