ಮಾಡ್ಯೂಲ್:KannadaDigitsToWestern
Documentation for this module may be created at ಮಾಡ್ಯೂಲ್:KannadaDigitsToWestern/doc
local p = {}
local western_digits = {
["೦"] = "0", ["೧"] = "1", ["೨"] = "2", ["೩"] = "3",
["೪"] = "4", ["೫"] = "5", ["೬"] = "6", ["೭"] = "7",
["೮"] = "8", ["೯"] = "9"
}
function p.convert(frame)
local input = tostring(frame.args[1])
local output = input:gsub("[೦-೯]", western_digits)
return output
end
return p