Skip to content

Instantly share code, notes, and snippets.

@omni5cience
omni5cience / gist:5080679
Last active December 14, 2015 11:39 — forked from graue/gist:5079734

NOTE: Scroll down for explanation (the difference turns out to be scoping, not closures per se).

$ cat juices.lua
local fruits = {"apple", "orange", "grape"}
local juicers = {}

for i,v in ipairs(fruits) do