foreach loop in lua code example Example: lua for each in table for k,v in pairs(table) do -- k is key -- v is value end