Quick actions

cmd+k|ctrl+k

Navigation

Languages

random number hider

Snippet info

Language

Lua

Visibility

public

Author

techhog

Created

2021-06-20T22:39:03.233374Z

Updated

2021-08-20T13:04:57.386858Z

function work(inp)
    local out = 'tonumber('
    numbers = {}
    
    tostring(inp):gsub('%d', function(a)
       table.insert(numbers, a)
    end)
    for i,n in pairs(numbers) do 
        out = out .. "'" .. tostring(n) .. "'"
        if #numbers > 1 and i < #numbers then
            out = out .. '..'
        end
    end
    out = out .. ')'
    return out
end 

local xd = work(19285619)
print(xd)
print(loadstring('print(' .. xd .. ')')())
INFO