Exercises, examples and other material relating to training module U103. This topic is presented on public courses
Learning to program in Lua,
Lua Programming
Lua Programming - Learning to program in Lua and make good use of the language
Our public "Lua Programming" course takes you from the
basics of the language
... http://www.wellho.net/course/ubfull.html [course] |
Learning to program in Lua - Learning to program in Lua and make good use of the language
"Learning to program in Lua" takes you from the basics of
computer ... http://www.wellho.net/course/ulfull.html [course] |
I have presented a bespoke Lua course over the last three days ... and it has lead me to some interesting new examples which I'm sharing here.
Object ... http://www.wellho.net/mouth/2455_Lua ... s-etc.html [short article] |
"Isn't there one standard way to say NOT?" asked one of my delegates on today's course - and it's an excellent question. But the answer to a question ... http://www.wellho.net/mouth/1696_Say ... -Lua-.html [short article] |
--[[ I have a lot of children ...
and I want to split some Christmas money between them ]]
give = 100
maxkids = 8
for numkids = 1,maxkids do
... http://www.wellho.net/resources/ex.php4?item=u103/kz [code sample] |
In Lua, if a partial expression evaluates to true the following section will NOT be evaluated if it follows an or because the whole thing cannot be true.
... http://www.wellho.net/mouth/1685_Sho ... n-Lua.html [short article] |
--[[
In Lua, if, elseif and else use then and end
clauses to delimit the conditional code
]]
j = 45
-- == for equality testing
if j==45 then print ("yes") ... http://www.wellho.net/resources/ex.php4?item=u103/lif [code sample] |
This topic is presented on public courses
Learning to program in Lua,
Lua Programming
Examples from our training material
| andor | Lazy and / or operators |
| bpm | string.find v string.gfind |
| clike | for loop with pairs and ipairs |
| clumpit | for loop termination |
| exa | Loops and conditionals - exchange rate example |
| floo | for loop in which end condition changes |
| kz | Example of a for loop |
| lif | if, elseif, else |
| ll2 | while loop and repeat until loop |
| lloops | while and for loops |
| tchart | for loop with start, end and step |
| wcd | Comparison of while and until loops |
| whilly | Writing cleaner code without break or continue |
Background information
Some modules are
available for download as a sample of our material or under an
Open Training Notes License for free download from
http://www.training-notes.co.uk.
Topics covered in this module
If while repeat break do and for.
Comparing numbers comparing strings.
Equality and nil.
Combining Conditions.
Complete learning
If you are looking for a complete course and not just a information on a single subject, visit our
Listing and schedule page.
Well House Consultants specialise in training courses in
Python,
Perl,
PHP, and
MySQL. We run
Private Courses throughout the UK (and beyond for longer courses), and
Public Courses at our training centre in Melksham, Wiltshire, England.
It's surprisingly cost effective to come on our public courses -
even if
you live in a different
country or continent to us.
We have a technical library of over 700 books on the subjects on which we teach.
These books are available for reference at our training centre. Also
available is the Opentalk
Forum for discussion of technical questions.