Created
December 4, 2010 21:52
-
-
Save asim/728514 to your computer and use it in GitHub Desktop.
just writing some lua
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local store = {} | |
local function add(key, value) | |
store[key] = value | |
end | |
local function get(key) | |
return store[key] | |
end | |
for k,v in pairs({ "foo", "bar", "zool" }) do | |
add(k, v) | |
end | |
for i=1,3 do | |
print(get(i)) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment