codepad
[
create a new paste
]
login
|
about
Language:
C
C++
D
Haskell
Lua
OCaml
PHP
Perl
Plain Text
Python
Ruby
Scheme
Tcl
local mt1 = { __index = { pie = "yummy" } } local mt2 = { __index = function(i) return i == "pie" and "yummy" end } local t1 = setmetatable({}, mt1) local t2 = setmetatable({}, mt2) print(next(t1)) print(next(t2))
Private
[
?
]
Run code
Submit