Content deleted Content added
# |
let's try this |
||
Line 36:
local input = args[1]
local match = { input:match('^([0-9][0-9]?) ([A-Za-z]+) ([0-9][0-9][0-9][0-9])$') }
if (match == nil) then return input .. ' -> is not a recognized pattern match' end
local month = monthIndices[match[2]:lower()]
Line 50 ⟶ 45:
local day = match[1]:tonumber()
local year = match[
return input .. ' -> parsed to ' .. year .. '-' .. month .. '-' .. day; -- won't add 0s
end
|