General > Developers Corner

Learning Lua... (Just a random post from a lua super noob.)

<< < (8/11) > >>

syn.:
oh okay thanks pres I didn't know the order of the values and stuff. It's
20
30
40
50
60
70
80
90
100

JamminR:
Got it syn.
I'll delve more into tables and table specific for loop functions in my next puzzle.
Not right now though. (it's now ~115am my time, and I'm running on fumes)

In your learning, are you finding any challenges/questions you're having trouble with specifically?
Perhaps I, or MrPresident if he so feels, could make a puzzle or two specifically aimed at challenges you're specifically having.

Also, i just realized, this post may better fit in developers corner (it's both off-topic to ULX, and, it is learning development/code logic.)

syn.:
not having many problems anymore thanks to Mr.Pres I think I'm ready for a tiny bit more :)

MrPresident:
Pick a topic.

JamminR:
Let's go table ipairs. :)
Just wait till I get to next statements inside the for loop.
Easy at first.

--- Code: ---x = { 0, 100, 20, 99 }
for k, v in ipairs( x ) do
   print ( k, v )
   if k == 3 then print ( "I found " .. v .. "!") end
end
--- End code ---

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version