右眼皮跳是什么预兆女| 圣灵是什么意思| 医保编码是什么| 什么是动态口令| 什么牌子的空调好| 膀胱炎吃什么药最见效| 川崎病是什么| 吃什么可以提高免疫力和抵抗力| 什么是包容| 蜜糖有什么功效和作用| 富甲一方什么意思| 学五行属什么| 孕中期头疼是什么原因| 职级是什么意思| 33年属什么生肖| 师字五行属什么| 为什么会心肌梗死| 21岁属什么生肖| 民营和私营有什么区别| 生酮是什么| 缅甸的首都叫什么名字| 三月24号是什么星座的| 十二指肠球炎是什么病| 风寒感冒吃什么药最快| 月加厷念什么| 取缔役什么意思| 40岁属什么生肖| 绿色衣服搭配什么颜色的裤子| 学什么设计最赚钱| 硒是什么| 花茶是什么茶| 男人阴虱用什么药| 9月出生的是什么星座| 血糖高的人适合吃什么水果| 池字五行属什么| 是什么意思啊| 宫颈囊肿多发是什么意思| 内招是什么意思| 阴毛长虱子用什么药| 自闭症是什么人投胎| 双子座是什么象| 积液是什么| 油菜籽什么时间种| 下半年有什么节日| 儿童红眼病用什么眼药水| 择日是什么意思| 梨子什么时候成熟| dm是什么病| 梦见长豆角是什么意思| 什么的眉毛| 减肥吃什么菜最好| 女人八卦是什么意思| 什么像什么什么| 香槟是什么| 挂妇科门诊都检查什么| 痔疮看什么科| 胸口长痘痘是什么原因| 戊肝阳性是什么意思| 章鱼的血是什么颜色| 硬座是什么意思| 花生什么时候种| 电风扇什么牌子好| 还是什么结构的字| 亲吻是什么意思| 康妇炎胶囊主治什么| 2月6日什么星座| 骨折长骨痂有什么反应| 肝内钙化灶是什么意思| 说一个人轴是什么意思| 毓婷是什么| 荔枝晒干了叫什么| 幼儿园转园需要什么手续| 耄耋之年是什么意思| 怀孕20天有什么症状| 肋间神经痛用什么药| 寮房是什么意思| 脸上有痣去医院挂什么科| 一个月来两次月经是什么原因| 农历五月二十八是什么日子| 什么样的疤痕影响当兵| 全麦是什么| 补钙吃什么最好| 牙齿根管治疗是什么意思| 膝关节退行性变是什么意思| 什么时候割包皮最好| 七一年属什么| 92年属什么| sara是什么意思| 右眼睛总跳是什么原因| 梦见盖新房子是什么意思| manu是什么意思| 阳历是什么| 尿盐结晶是什么意思| 霸王别姬是什么菜| 什么情况下需要安装心脏起搏器| 迪根是什么药| 10000是什么电话| 尿液白细胞高是什么原因| 润滑油是干什么用的| 脂肪瘤看什么科| 譬如是什么意思| 发烧吃什么好| 喝山楂泡水有什么功效| 三伏天什么意思| 白羊座是什么性格| 腰闪了是什么症状| 流苏是什么意思| 伤口感染化脓用什么药| 狗子是什么意思| 雍是什么意思| 公务员五行属什么| 土鳖是什么意思| ad是什么的缩写| 双相情感障碍吃什么药| 半夜饿是什么原因| 梦见买狗是什么意思| 为什么会便秘| 死去活来是什么生肖| 腰扭伤挂什么科| 521代表什么含义| 引什么大叫| 90年属什么的生肖| 阿奇霉素和头孢有什么区别| 风云人物什么意思| 渗湿是什么意思| 老舍原名什么| 什么是情商高| 黄痰是什么原因| q热是什么病| 维生素d3吃多了有什么副作用| 说什么情深似海我却不敢当| 十九朵玫瑰花代表什么意思| 一诺千金是什么意思| gigi 是什么意思| 喉咙一直有痰是什么原因| bur什么意思| 第二次世界大战是什么时候| 211什么意思| 肠胃不舒服挂什么科| 双离合什么意思| pao2是什么意思| 百无一用是什么意思| 什么值得买官网| 可可尼女装什么档次| 回盲部憩室是什么意思| 甲钴胺片是什么药| 木薯淀粉是什么粉| 1985年属什么| 黑马是什么意思| 孕妇吃红薯对胎儿有什么好处| 言外之意什么意思| 女同什么意思| 肚脐左侧按压疼是什么原因| 甲沟炎用什么药膏| 寓言故事有什么特点| 10月1是什么星座| 子宫内膜厚有什么影响| 身心合一是什么意思| 疱疹是什么症状| 颈动脉有斑块吃什么药| 胃酸是什么颜色的| 高尿酸有什么症状| 晶莹剔透是什么意思| 籍贯指的是什么| 流产是什么症状| 风寒感冒吃什么| joway是什么牌子| 非萎缩性胃窦炎是什么意思| 突然头昏是什么原因引起的| uno是什么| 细菌性阴道炎用什么药好| 晚上尿多是什么病| 籽料是什么意思| 焦的部首是什么| 面部痉挛是什么原因引起的| 开塞露用多了有什么副作用| 六腑指的是什么| 当归有什么功效| 虾不能和什么东西一起吃| 地府是什么意思| 平安顺遂什么意思| 来大姨妈不能吃什么水果| 茄子与什么相克| 体检需要带什么| 腱鞘囊肿看什么科| 梦见蛇是什么预兆| 蚊虫叮咬用什么药膏| 小便分叉是什么原因男| 5月13号是什么星座| 左侧淋巴结肿大是什么原因| 一会硬一会软什么情况| s 是什么意思| 上环后需要注意什么| 仓鼠可以吃什么蔬菜| 一个火一个斤念什么| 吃桑葚有什么好处| 血糖高吃什么可以降下来| 七夕送什么礼物好| 阻滞是什么意思| 什么水果糖分最低| 学五行属什么| 桑寄生有什么功效| 小孩子记忆力差是什么原因| 藏族信仰什么教| 唐顿庄园讲的是什么| 芥菜长什么样子图片| 李白被人们称为什么| 红色的补色是什么颜色| thc是什么费用| 质询是什么意思| 低血糖挂什么科| 内膜薄吃什么增长最快| 吹气检查胃是检查什么| 孕妇不吃饭对胎儿有什么影响| 生旦净末丑分别指什么| camp医学上是什么意思| 黄体酮吃多了有什么副作用| 三个女人一台戏什么意思| 为什么会长闭口粉刺| 人为什么打嗝| 高血压挂什么科| 指甲花学名叫什么| degaia是什么牌子| 95年的属什么| 女生下面是什么样的| 什么动物最没有方向感| 喝酒上脸是什么原因| 火疖子挂什么科| 庆五行属什么| 招采是什么意思| 月经提前来是什么原因| 权衡利弊是什么意思| 糖尿病适合吃什么水果| 区级以上医院是什么意思| 马甲线长什么样| 感染四项挂什么科| 14楼五行属什么| guess是什么意思| 过是什么结构的字| 蒲公英长什么样子| 真菌感染吃什么药| 表姐的女儿叫什么| 武汉都有什么区| 空腹喝什么茶| 假性宫缩是什么感觉| 验光是什么意思| 日本为什么侵略中国| 慢性炎伴鳞化是什么意思| 什么鱼是深海鱼| 腿有淤青是什么原因| 有口臭是什么原因| 混油皮是什么意思| 土阜念什么| 劲酒是什么酒| 脑梗前有什么预兆| 关节退行性改变是什么意思| 高压低是什么原因引起的| 红加黄等于什么颜色| 南瓜炒什么好吃| 低脂牛奶适合什么人喝| 双鱼座上升星座是什么| 什么叫hp感染| sport是什么意思| 基础代谢是什么意思| 百度K?rceni tek p?rmbajtja

握手言和是什么意思

Nga Wikipedia, enciklopedia e lir?
百度 做好全省职称评审数据归集和应用工作。
------------------------------------------------------------------------------------
--                                   TableTools                                   --
--                                                                                --
-- This module includes a number of functions for dealing with Lua tables.        --
-- It is a meta-module, meant to be called from other Lua modules, and should not --
-- be called directly from #invoke.                                               --
------------------------------------------------------------------------------------

local libraryUtil = require('libraryUtil')

local p = {}

-- Define often-used variables and functions.
local floor = math.floor
local infinity = math.huge
local checkType = libraryUtil.checkType
local checkTypeMulti = libraryUtil.checkTypeMulti

------------------------------------------------------------------------------------
-- isPositiveInteger
--
-- This function returns true if the given value is a positive integer, and false
-- if not. Although it doesn't operate on tables, it is included here as it is
-- useful for determining whether a given table key is in the array part or the
-- hash part of a table.
------------------------------------------------------------------------------------
function p.isPositiveInteger(v)
	return type(v) == 'number' and v >= 1 and floor(v) == v and v < infinity
end

------------------------------------------------------------------------------------
-- isNan
--
-- This function returns true if the given number is a NaN value, and false if
-- not. Although it doesn't operate on tables, it is included here as it is useful
-- for determining whether a value can be a valid table key. Lua will generate an
-- error if a NaN is used as a table key.
------------------------------------------------------------------------------------
function p.isNan(v)
	return type(v) == 'number' and v ~= v
end

------------------------------------------------------------------------------------
-- shallowClone
--
-- This returns a clone of a table. The value returned is a new table, but all
-- subtables and functions are shared. Metamethods are respected, but the returned
-- table will have no metatable of its own.
------------------------------------------------------------------------------------
function p.shallowClone(t)
	checkType('shallowClone', 1, t, 'table')
	local ret = {}
	for k, v in pairs(t) do
		ret[k] = v
	end
	return ret
end

------------------------------------------------------------------------------------
-- removeDuplicates
--
-- This removes duplicate values from an array. Non-positive-integer keys are
-- ignored. The earliest value is kept, and all subsequent duplicate values are
-- removed, but otherwise the array order is unchanged.
------------------------------------------------------------------------------------
function p.removeDuplicates(arr)
	checkType('removeDuplicates', 1, arr, 'table')
	local isNan = p.isNan
	local ret, exists = {}, {}
	for _, v in ipairs(arr) do
		if isNan(v) then
			-- NaNs can't be table keys, and they are also unique, so we don't need to check existence.
			ret[#ret + 1] = v
		elseif not exists[v] then
			ret[#ret + 1] = v
			exists[v] = true
		end
	end
	return ret
end

------------------------------------------------------------------------------------
-- numKeys
--
-- This takes a table and returns an array containing the numbers of any numerical
-- keys that have non-nil values, sorted in numerical order.
------------------------------------------------------------------------------------
function p.numKeys(t)
	checkType('numKeys', 1, t, 'table')
	local isPositiveInteger = p.isPositiveInteger
	local nums = {}
	for k in pairs(t) do
		if isPositiveInteger(k) then
			nums[#nums + 1] = k
		end
	end
	table.sort(nums)
	return nums
end

------------------------------------------------------------------------------------
-- affixNums
--
-- This takes a table and returns an array containing the numbers of keys with the
-- specified prefix and suffix. For example, for the table
-- {a1 = 'foo', a3 = 'bar', a6 = 'baz'} and the prefix "a", affixNums will return
-- {1, 3, 6}.
------------------------------------------------------------------------------------
function p.affixNums(t, prefix, suffix)
	checkType('affixNums', 1, t, 'table')
	checkType('affixNums', 2, prefix, 'string', true)
	checkType('affixNums', 3, suffix, 'string', true)

	local function cleanPattern(s)
		-- Cleans a pattern so that the magic characters ()%.[]*+-?^$ are interpreted literally.
		return s:gsub('([%(%)%%%.%[%]%*%+%-%?%^%$])', '%%%1')
	end

	prefix = prefix or ''
	suffix = suffix or ''
	prefix = cleanPattern(prefix)
	suffix = cleanPattern(suffix)
	local pattern = '^' .. prefix .. '([1-9]%d*)' .. suffix .. '$'

	local nums = {}
	for k in pairs(t) do
		if type(k) == 'string' then
			local num = mw.ustring.match(k, pattern)
			if num then
				nums[#nums + 1] = tonumber(num)
			end
		end
	end
	table.sort(nums)
	return nums
end

------------------------------------------------------------------------------------
-- numData
--
-- Given a table with keys like {"foo1", "bar1", "foo2", "baz2"}, returns a table
-- of subtables in the format
-- {[1] = {foo = 'text', bar = 'text'}, [2] = {foo = 'text', baz = 'text'}}.
-- Keys that don't end with an integer are stored in a subtable named "other". The
-- compress option compresses the table so that it can be iterated over with
-- ipairs.
------------------------------------------------------------------------------------
function p.numData(t, compress)
	checkType('numData', 1, t, 'table')
	checkType('numData', 2, compress, 'boolean', true)
	local ret = {}
	for k, v in pairs(t) do
		local prefix, num = mw.ustring.match(tostring(k), '^([^0-9]*)([1-9][0-9]*)$')
		if num then
			num = tonumber(num)
			local subtable = ret[num] or {}
			if prefix == '' then
				-- Positional parameters match the blank string; put them at the start of the subtable instead.
				prefix = 1
			end
			subtable[prefix] = v
			ret[num] = subtable
		else
			local subtable = ret.other or {}
			subtable[k] = v
			ret.other = subtable
		end
	end
	if compress then
		local other = ret.other
		ret = p.compressSparseArray(ret)
		ret.other = other
	end
	return ret
end

------------------------------------------------------------------------------------
-- compressSparseArray
--
-- This takes an array with one or more nil values, and removes the nil values
-- while preserving the order, so that the array can be safely traversed with
-- ipairs.
------------------------------------------------------------------------------------
function p.compressSparseArray(t)
	checkType('compressSparseArray', 1, t, 'table')
	local ret = {}
	local nums = p.numKeys(t)
	for _, num in ipairs(nums) do
		ret[#ret + 1] = t[num]
	end
	return ret
end

------------------------------------------------------------------------------------
-- sparseIpairs
--
-- This is an iterator for sparse arrays. It can be used like ipairs, but can
-- handle nil values.
------------------------------------------------------------------------------------
function p.sparseIpairs(t)
	checkType('sparseIpairs', 1, t, 'table')
	local nums = p.numKeys(t)
	local i = 0
	local lim = #nums
	return function ()
		i = i + 1
		if i <= lim then
			local key = nums[i]
			return key, t[key]
		else
			return nil, nil
		end
	end
end

------------------------------------------------------------------------------------
-- size
--
-- This returns the size of a key/value pair table. It will also work on arrays,
-- but for arrays it is more efficient to use the # operator.
------------------------------------------------------------------------------------
function p.size(t)
	checkType('size', 1, t, 'table')
	local i = 0
	for _ in pairs(t) do
		i = i + 1
	end
	return i
end

local function defaultKeySort(item1, item2)
	-- "number" < "string", so numbers will be sorted before strings.
	local type1, type2 = type(item1), type(item2)
	if type1 ~= type2 then
		return type1 < type2
	elseif type1 == 'table' or type1 == 'boolean' or type1 == 'function' then
		return tostring(item1) < tostring(item2)
	else
		return item1 < item2
	end
end
------------------------------------------------------------------------------------
-- keysToList
--
-- Returns an array of the keys in a table, sorted using either a default
-- comparison function or a custom keySort function.
------------------------------------------------------------------------------------
function p.keysToList(t, keySort, checked)
	if not checked then
		checkType('keysToList', 1, t, 'table')
		checkTypeMulti('keysToList', 2, keySort, {'function', 'boolean', 'nil'})
	end

	local arr = {}
	local index = 1
	for k in pairs(t) do
		arr[index] = k
		index = index + 1
	end

	if keySort ~= false then
		keySort = type(keySort) == 'function' and keySort or defaultKeySort
		table.sort(arr, keySort)
	end

	return arr
end

------------------------------------------------------------------------------------
-- sortedPairs
--
-- Iterates through a table, with the keys sorted using the keysToList function.
-- If there are only numerical keys, sparseIpairs is probably more efficient.
------------------------------------------------------------------------------------
function p.sortedPairs(t, keySort)
	checkType('sortedPairs', 1, t, 'table')
	checkType('sortedPairs', 2, keySort, 'function', true)

	local arr = p.keysToList(t, keySort, true)

	local i = 0
	return function ()
		i = i + 1
		local key = arr[i]
		if key ~= nil then
			return key, t[key]
		else
			return nil, nil
		end
	end
end

------------------------------------------------------------------------------------
-- isArray
--
-- Returns true if the given value is a table and all keys are consecutive
-- integers starting at 1.
------------------------------------------------------------------------------------
function p.isArray(v)
	if type(v) ~= 'table' then
		return false
	end
	local i = 0
	for _ in pairs(v) do
		i = i + 1
		if v[i] == nil then
			return false
		end
	end
	return true
end

------------------------------------------------------------------------------------
-- isArrayLike
--
-- Returns true if the given value is iterable and all keys are consecutive
-- integers starting at 1.
------------------------------------------------------------------------------------
function p.isArrayLike(v)
	if not pcall(pairs, v) then
		return false
	end
	local i = 0
	for _ in pairs(v) do
		i = i + 1
		if v[i] == nil then
			return false
		end
	end
	return true
end

------------------------------------------------------------------------------------
-- invert
--
-- Transposes the keys and values in an array. For example, {"a", "b", "c"} ->
-- {a = 1, b = 2, c = 3}. Duplicates are not supported (result values refer to
-- the index of the last duplicate) and NaN values are ignored.
------------------------------------------------------------------------------------
function p.invert(arr)
	checkType("invert", 1, arr, "table")
	local isNan = p.isNan
	local map = {}
	for i, v in ipairs(arr) do
		if not isNan(v) then
			map[v] = i
		end
	end

	return map
end

------------------------------------------------------------------------------------
-- listToSet
--
-- Creates a set from the array part of the table. Indexing the set by any of the
-- values of the array returns true. For example, {"a", "b", "c"} ->
-- {a = true, b = true, c = true}. NaN values are ignored as Lua considers them
-- never equal to any value (including other NaNs or even themselves).
------------------------------------------------------------------------------------
function p.listToSet(arr)
	checkType("listToSet", 1, arr, "table")
	local isNan = p.isNan
	local set = {}
	for _, v in ipairs(arr) do
		if not isNan(v) then
			set[v] = true
		end
	end

	return set
end

------------------------------------------------------------------------------------
-- deepCopy
--
-- Recursive deep copy function. Preserves identities of subtables.
------------------------------------------------------------------------------------
local function _deepCopy(orig, includeMetatable, already_seen)
	if type(orig) ~= "table" then
		return orig
	end
	
	-- already_seen stores copies of tables indexed by the original table.
	local copy = already_seen[orig]
	if copy ~= nil then
		return copy
	end
	
	copy = {}
	already_seen[orig] = copy -- memoize before any recursion, to avoid infinite loops
	
	for orig_key, orig_value in pairs(orig) do
		copy[_deepCopy(orig_key, includeMetatable, already_seen)] = _deepCopy(orig_value, includeMetatable, already_seen)
	end
	
	if includeMetatable then
		local mt = getmetatable(orig)
		if mt ~= nil then
			setmetatable(copy, _deepCopy(mt, true, already_seen))
		end
	end
	
	return copy
end

function p.deepCopy(orig, noMetatable, already_seen)
	checkType("deepCopy", 3, already_seen, "table", true)
	return _deepCopy(orig, not noMetatable, already_seen or {})
end

------------------------------------------------------------------------------------
-- sparseConcat
--
-- Concatenates all values in the table that are indexed by a number, in order.
-- sparseConcat{a, nil, c, d}  =>  "acd"
-- sparseConcat{nil, b, c, d}  =>  "bcd"
------------------------------------------------------------------------------------
function p.sparseConcat(t, sep, i, j)
	local arr = {}

	local arr_i = 0
	for _, v in p.sparseIpairs(t) do
		arr_i = arr_i + 1
		arr[arr_i] = v
	end

	return table.concat(arr, sep, i, j)
end

------------------------------------------------------------------------------------
-- length
--
-- Finds the length of an array, or of a quasi-array with keys such as "data1",
-- "data2", etc., using an exponential search algorithm. It is similar to the
-- operator #, but may return a different value when there are gaps in the array
-- portion of the table. Intended to be used on data loaded with mw.loadData. For
-- other tables, use #.
-- Note: #frame.args in frame object always be set to 0, regardless of  the number
-- of unnamed template parameters, so use this function for frame.args.
------------------------------------------------------------------------------------
function p.length(t, prefix)
	-- requiring module inline so that [[Module:Exponential search]] which is
	-- only needed by this one function doesn't get millions of transclusions
	local expSearch = require("Module:Exponential search")
	checkType('length', 1, t, 'table')
	checkType('length', 2, prefix, 'string', true)
	return expSearch(function (i)
		local key
		if prefix then
			key = prefix .. tostring(i)
		else
			key = i
		end
		return t[key] ~= nil
	end) or 0
end

------------------------------------------------------------------------------------
-- inArray
--
-- Returns true if searchElement is a member of the array, and false otherwise.
-- Equivalent to JavaScript array.includes(searchElement) or
-- array.includes(searchElement, fromIndex), except fromIndex is 1 indexed
------------------------------------------------------------------------------------
function p.inArray(array, searchElement, fromIndex)
	checkType("inArray", 1, array, "table")
	-- if searchElement is nil, error?

	fromIndex = tonumber(fromIndex)
	if fromIndex then
		if (fromIndex < 0) then
			fromIndex = #array + fromIndex + 1
		end
		if fromIndex < 1 then fromIndex = 1 end
		for _, v in ipairs({unpack(array, fromIndex)}) do
			if v == searchElement then
				return true
			end
		end
	else
		for _, v in pairs(array) do
			if v == searchElement then
				return true
			end
		end
	end
	return false
end

------------------------------------------------------------------------------------
-- merge
--
-- Given the arrays, returns an array containing the elements of each input array
-- in sequence.
------------------------------------------------------------------------------------
function p.merge(...)
	local arrays = {...}
	local ret = {}
	for i, arr in ipairs(arrays) do
		checkType('merge', i, arr, 'table')
		for _, v in ipairs(arr) do
			ret[#ret + 1] = v
		end
	end
	return ret
end

------------------------------------------------------------------------------------
-- extend
--
-- Extends the first array in place by appending all elements from the second
-- array.
------------------------------------------------------------------------------------
function p.extend(arr1, arr2)
	checkType('extend', 1, arr1, 'table')
	checkType('extend', 2, arr2, 'table')

	for _, v in ipairs(arr2) do
		arr1[#arr1 + 1] = v
	end
end

return p
梦见买碗是什么意思 早上十点是什么时辰 短发适合什么脸型 觉是什么结构 单立人加吉念什么
一本万利是什么意思 mcm中文叫什么牌子 10周年结婚是什么婚 鲫鱼是什么鱼 终身是什么意思
乘载和核载是什么意思 脚有酸味是什么原因 血红蛋白是查什么的 基质是什么 仓鼠突然死了是为什么
舌头干燥是什么原因 天津为什么叫天津卫 泄气的意思是什么 身上很痒是什么原因 985是什么意思
lt是什么意思hcv8jop3ns8r.cn arf是什么意思cj623037.com 无意间是什么意思hanqikai.com 生理期肚子疼吃什么药bysq.com 健康管理师是干什么的jingluanji.com
豚鼠吃什么食物hcv8jop8ns0r.cn 猫咪来家里是什么寓意hcv9jop5ns8r.cn 有人的地方就有江湖什么意思hcv8jop6ns7r.cn 吃什么能立马催月经hcv8jop9ns5r.cn 月亮五行属什么youbangsi.com
眼睛经常充血是什么原因引起的hcv9jop5ns4r.cn 油头粉面是什么意思hcv9jop0ns2r.cn 什么颜色加什么颜色是红色hcv8jop1ns1r.cn 2倍是什么意思jasonfriends.com 孩子白细胞高是什么原因hcv8jop1ns5r.cn
广角是什么hcv8jop5ns5r.cn 大便不成形用什么药bfb118.com alt医学上是什么意思hcv8jop9ns0r.cn 喝生姜水有什么好处hcv9jop4ns0r.cn 脂肪肝可以吃什么水果hcv8jop2ns7r.cn
百度