বিষয়বস্তুতে চলুন

মডিউল:number list/data/haw

উইকিঅভিধান, মুক্ত অভিধান থেকে

এই মডিউলের জন্য মডিউল:number list/data/haw/নথি-এ নথিপত্র তৈরি করা হয়ে থাকতে পারে

local export = {numbers = {}}

local numbers = export.numbers

export.additional_number_types = {
	{ key = "base", display = "Base form", before = "cardinal" },
}

local card_pre = "ʻe"
local dist_pre = "pā"
local frac_pre = "hapa"
local plus = "kūmā"
local ten_pre = "kana"

numbers[0] = {
	base = "ʻole",
	cardinal = "ʻole",
}
numbers[1] = {
	base = "kahi",
}

numbers[2] = {
	base = "lua",
}

numbers[3] = {
	base = "kolu",
}

numbers[4] = {
	base = "hā",
}

numbers[5] = {
	base = "lima",
}

numbers[6] = {
	base = "ono",
}

numbers[7] = {
	base = "hiku",
}

numbers[8] = {
	base = "walu",
}

numbers[9] = {
	base = "iwa",
}

-- Create cardinal + ordinal for 1-9
for number = 1, 9 do 
	numbers[number].cardinal = card_pre .. numbers[number].base 
	if number ~= 1 then
		numbers[number].ordinal = numbers[number].base
	else 
		numbers[number].ordinal = "mua"
	end
end

numbers[10] = {
	base = "ʻumi",
	cardinal = "ʻumi",
	ordinal = "ʻumi",
}

-- Create distributives + fractionals
for number = 1, 10 do
	numbers[number].distributive = dist_pre .. numbers[number].base 
	if number ~= 1 then
		numbers[number].fractional = frac_pre .. numbers[number].base 
	end
end 

-- Create teens
for number = 11, 19 do
	base_num = number - 10
	ten = numbers[10].cardinal 
	numbers[number] = {
		cardinal = ten .. plus .. numbers[base_num].base
	}
end

numbers[20] = {
	cardinal = "iwakālua",
	distributive = "pāiwakālua",
}

-- Create twenties
for number = 21, 29 do
	base_num = number - 20
	twenty = numbers[20].cardinal 
	numbers[number] = {
		cardinal = twenty .. plus .. numbers[base_num].base
	}
end

-- Create tens + in-betweens
for number = 3, 9 do
	tens = number * 10
	numbers[tens] = {
		cardinal = ten_pre .. numbers[number].base
	}
	tens_card = numbers[tens].cardinal
	numbers[tens].distributive = dist_pre .. tens_card
	for ones = 1,9 do
		numbers[tens + ones] = {
			cardinal = tens_card .. plus .. numbers[ones].base
		}
	end
end

numbers[100] = {
	cardinal = {"hoʻokahi haneli","haneli<q:used in compounds>"},
	distributive = "pāhaneli",
}

numbers[1000] = {
	cardinal = {"hoʻokahi kaukani","kaukani<q:used in compounds>"},
	distributive = "pākaukani",
}

numbers[1000000] = {
	cardinal = "miliona",
	distributive = "pāmiliona",
}

numbers[1000000000] = {
	cardinal = "piliona",
	distributive = "pāpiliona",
}

numbers[1000000000000] = {
	cardinal = "kiliona",
	distributive = "pākiliona",
}

-- Update "1" cardinal
numbers[1].cardinal = {"hoʻokahi", numbers[1].cardinal}

-- Add base-4 numerals
numbers[4].cardinal = {numbers[4].cardinal, "kāuna<q:traditional>"}
numbers[40].cardinal = {numbers[40].cardinal, "kaʻau<q:traditional>"}
numbers[400] = {
	cardinal = {"[[ʻehā]] [[haneli]]", "lua<q:traditional>"}
}
numbers[4000] = {
	cardinal = {"[[ʻehā]] [[kaukani]]", "mano<q:traditional>"}
}
numbers[40000] = {
	cardinal = {"[[kanahā]] [[kaukani]]", "kini<q:traditional>"}
}
numbers[400000] = {
	cardinal = {"[[ʻehā]] [[haneli]] [[kaukani]]", "lehulehu<q:traditional, disputed>"}
}

return export