Created
January 20, 2020 07:25
-
-
Save PedroAlvesV/fa38ec07a038deb9ed0bfe118fb6627a to your computer and use it in GitHub Desktop.
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 function print_table(t, level) | |
level = level or 0 | |
local tab = "" | |
for i=1, level do | |
tab = tab.."\t" | |
end | |
for k,v in pairs(t) do | |
if type(v)=="table" then | |
print(tab..k) | |
print_table(v, level+1) | |
else | |
print(tab..k.." "..v) | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment