Module:User:Hermes Thrice Great/bo-common

Hello, you have come here looking for the meaning of the word Module:User:Hermes Thrice Great/bo-common. In DICTIOUS you will not only get to know all the dictionary meanings for the word Module:User:Hermes Thrice Great/bo-common, but we will also tell you about its etymology, its characteristics and you will know how to say Module:User:Hermes Thrice Great/bo-common in singular and plural. Everything you need to know about the word Module:User:Hermes Thrice Great/bo-common you have here. The definition of the word Module:User:Hermes Thrice Great/bo-common will help you to be more precise and correct when speaking or writing your texts. Knowing the definition ofModule:User:Hermes Thrice Great/bo-common, as well as those of other words, enriches your vocabulary and provides you with more and better linguistic resources.


local export = {}
local match = mw.ustring.match
local gsub = mw.ustring.gsub

function split(str, pat)
   local t = {}  -- NOTE: use {n = 0} in Lua-5.0
   local fpat = "(.-)" .. pat
   local last_end = 1
   local s, e, cap = str:find(fpat, 1)
   while s do
      if s ~= 1 or cap ~= "" then
         table.insert(t, cap)
      end
      last_end = e+1
      s, e, cap = str:find(fpat, last_end)
   end
   if last_end <= #str then
      cap = str:sub(last_end)
      table.insert(t, cap)
   end
   return t
end

function export.verb(frame)
	local title = mw.title.getCurrentTitle().text
	local tr_title = require("Module:Tibt-translit").tr(title, "bo", "Tibt")
    local tr_split_title = split(tr_title,'+')
    local s = { match(tr_split_title, (gsub(tr_split_title, ".", "(.)"))) }
    local i = table.getn(s) - 1
    local j = i - 1
	if match(s, "") or (s == "n" and s == "g") then
		return "བ"
	end
	return "པ"
end

return export