Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR LUA

how to split strings into 2 string by space lua

function mysplit (inputstr, sep)
        if sep == nil then
                sep = "%s"
        end
        local t={}
        for str in string.gmatch(inputstr, "([^"..sep.."]+)") do
                table.insert(t, str)
        end
        return t
end
 
PREVIOUS NEXT
Tagged: #split #strings #string #space #lua
ADD COMMENT
Topic
Name
7+3 =