••• NUMBERTEXT.org ••• IDE of Soros programming language (
specification
)
Back
C
ountry:
P
refix:
I
nput:
Output:
Program
e
ditor
L
oad:
New module
Tutorial – Part 1
Tutorial – Part 2
Tutorial – Part 3
Tutorial – Part 4
Tutorial – Part 5
af
bg
ca
cs
da
de
el
en
eo
es
et
fa
fi
fr
ga
gl
he
hr
hu
id
is
it
ja
ko
lb
lg
lt
lv
mr
ms
mt
nl
no
pl
pt
ro
ru
sh
sk
sl
sq
sr
sv
th
tr
uk
vi
zh
Roman
Suzhou
hu Hung
mul
# Soros Tutorial – Part One 🔢 Three, Two, One... # # INTRODUCTION # # Soros programming language is for number to # number name conversion. It’s based on regular # expressions, the popular text processing # tool of modern programming languages. So if you # don’t want to convert numbers to number names, # it’s still worth to check this tutorial, because # most parts are about regular expressions, # giving useful information for modern C++, Java, # JavaScript, Python etc. programming, too. # If you know regular expressions well, you can # jump to the last part of the tutorial! # # In this part, we will learn the base syntax of # Soros, writing small programs to convert # input numbers to numbers and colorful (at least # in Mozilla Firefox) emojis! # # # # TASK 1 – HELLO, WORLD! # # A Soros program consists of program lines. # # A program line is an input text and an output text # separated by (the first) space: # # input_text output text # # Following program line replaces the input text “0” # with the output text “Hello, 🌍!”, as you can see # in the right output list window, which shows the # output of the first 120 integer numbers, including # this one: 0 Hello, 🌍! # Replace “Hello, 🌍!” with “zero” in the previous line, # and check the same change in the right output window # list! # # Write here a new program line to convert the input # text “1” to “one”! # TASK 2 – The early bird catches the worm. # # First matching program line gives result. # # Remove the line with the bird COMPLETELY, and # then the line with the worm! During these, check # the results in the right output list window! 2 🐦 2 🐛 2 two # TASK 3 – Three blind mice # # Input text without matching program line, or a # matching program line without output text # results empty output text. # # Remove the character # (sign of comment line) # before 3 in the following line to hide the mice! #3 3 🐁🐁🐁 # TASK 4 – Five little speckled frogs # # Modify the following program lines to get correct # number of frogs for the input number 5 and 4! 5 🐸🐸🐸🐸🐸🐸 4 🐸🐸🐸🐸🐸🐸 SCROLL DOWN FOR SOLUTION ⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩ # Solution – TASK 4 # # 5 🐸🐸🐸🐸🐸 # 4 🐸🐸🐸🐸 ###################################################### # CONGRATULATIONS – You have finished Tutorial One! 🙂 ######################################################
# Soros Tutorial Two 🍒 Fruitful Expressions # # We learn the basics of regular expressions, # writing a program to convert even input # numbers to apples, and odd numbers to pears. # # INTRODUCTION # # Regular expression (regexp or regex or RE) is # a standard for pattern matching and replacement, # supported by every modern programming languages. # # Why? Because it’s the easiest way to handle # input texts. # # A Soros program line can be a regular # expression pattern and replacement: # # regex_pattern regex replacement # TASK 1 # # The character . (dot) matches arbitrary # characters in a regex pattern. # # Remove the # in the following program to add # bananas to all 1-digit numbers (except one), # and tangerines to all 2-digit numbers, and extend # the third program line to convert all 3-digit # numbers to pineapples (scroll the output # window to the end to see 3-digit numbers)! 1 one #. 🍌 (1-DIGIT) #.. 🍊 (2-DIGIT) 🍍 # NOTE: Solutions are there in the end of this tutorial. # TASK 2 # # Dots can be combined with arbitrary other # characters. # # Extend the previous program with a single # program line to replace 10, 20, 30 ... 90 # with lemons instead of bananas! # (Copy this lemon emoji: 🍋). # # TASK 3 # # We can limit the previous pattern only for # given characters, putting them between brackets. # # For example, [abcd] matches only the letter a, b, c and d. # # Add a *single* program line to the previous program to # to replace every 2-digit *even* number with an apple, ie. # compressing the following 45-line long program: # # 10 🍎 (EVEN) # 12 🍎 (EVEN) # ... # 98 🍎 (EVEN) # TASK 4 # # The .+ (dot plus) matches 1 or more arbitrary characters. # # What will be the effect of the following program line, if # you change the first line “1 one” with it, and remove the # sign of comment? Guess it, and check it! #.+ 🍎🍎🍎 # TASK 5 # # We can combine the different regex patterns, for example, the # dot plus pattern with the bracket one. # # Write a program from scratch (removing the old program lines) # to show apples and pears for every 2-digit or more input # number, using .+ and bracket expressions! # # 10 🍎 (EVEN) # 11 🍐 (ODD) # 12 🍎 (EVEN) # ... # 100 🍎 (EVEN) # 101 🍐 (ODD) # etc. # TASK 6 # # The .* (dot asterisk) matches 0 or more arbitrary characters. # # Replace the first program line “1 one” with a program line to # convert all even input numbers (including the 1-letter ones) # to apples, and insert a new program line to convert all # odd numbers to pears. SCROLL DOWN FOR SOLUTIONS ⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩ # SOLUTION – TASK 1 # # 1 one # . 🍌 (1-DIGIT) # .. 🍊 (2-DIGIT) # ... 🍍 (3-DIGIT) # SOLUTION – TASK 2 # # 1 one # . 🍌 (1-DIGIT) # .0 🍋 (10×n) # .. 🍊 (2-DIGIT) # ... 🍍 (3-DIGIT) # SOLUTION – TASK 3 # # 1 one # . 🍌 (1-DIGIT) # .[02468] 🍎 (EVEN 2-DIGIT) # .0 🍋 (10×n) # .. 🍊 (2-DIGIT) # ... 🍍 (3-DIGIT) # SOLUTION – TASK 4 # # All numbers converted to "🍎🍎🍎", because .+ matches # every input text, so the following program lines # will never be executed, so we can remove them: # # .+ 🍎🍎🍎 # SOLUTION – TASK 5 # # 2-digit or bigger numbers are converted to # apples and pears by the following two lines: # # .+[02468] 🍎 (EVEN 2-OR-MORE-DIGIT) # .+[13579] 🍐 (ODD 2-OR-MORE-DIGIT) # # or simply # # .+[02468] 🍎 (EVEN 2-OR-MORE-DIGIT) # .+. 🍐 (ODD 2-OR-MORE-DIGIT) # SOLUTION – TASK 6 # # Change + with * in the previous program to convert # every (1-digit or larger) number to apples and pears: # # .*[02468] 🍎 (EVEN NUMBER) # .* 🍐 (ODD NUMBER) ###################################################### # CONGRATULATIONS – You have finished Tutorial Two! 🙂 ######################################################
# Soros Tutorial Three 🛠️ Hello, Real World! # # Using the simplest regex reference # we solve a typical Soros problem, converting # numbers to ordinal abbreviations. # # # INTRODUCTION # # Syntax of a Soros program line: # # regex_pattern regex replacement # # The \0 (backslash zero) in the regex replacement # is a reference for the input number. # # For example, the following program line match every # input number and replace it by ownself, i.e. we get # back the input number without any changes, as you can # see in the right output list window after removing # the # at the beginning of the line: #.* \0 # TASK 1 # # It’s possible to refer the input number multiple times # in the same regex_replacement, combined with arbitrary # text. # # Modify the *previous program line* to greet the input # number double, as follows! # # 1 -> Hello, 1! Hi, 1! # 2 -> Hello, 2! Hi, 2! # TASK 2 # # Complete the program of Tutorial 1 to handle all # English ordinal abbreviations! # # Rules: # # I Every word ending with 1, 2, 3 has got an # abbreviation ending with 1st, 2nd, 3rd, # for example, 1 -> 1st (first), 22 -> 22nd # (twenty-second), 103 -> 103rd (one hundred third). # # Ib Exception: numbers ending with 11, 12 or 13. # Example: 11 -> 11th (eleventh), 112 -> 112th # (one hundred twelfth), 1013 -> 1013th # (one thousand and thirteenth). # # II Other numbers get “th”. Example: 4 -> 4th (fourth). SCROLL DOWN FOR SOLUTIONS ⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩ # SOLUTION – TASK 1 # # .* HELLO, \0! HI, \0! # SOLUTION – TASK 2 # # The trick is there in the first line, # a pattern to match all input # ending with 1., for example, 10, 11, .. 19, # 110, 111 etc.: # # .*1. \0th # .*1 \0st # .*2 \0nd # .*3 \0rd # .* \0th ######################################################## # CONGRATULATIONS – You have finished Tutorial Three! 🙂 ########################################################
# Soros Tutorial Four 👪 Reference & Group # # We will write a thousand separation program # by referring parts of the input text and # learning more about regular expression syntax. # # # # TASK 1 # # We can create character groups in the regex pattern by # parenthesizing, and refer them using reference \1..\9 # in the regex replacement. # # For example, following program replaces the # characters of arbitry 2-character input (ab -> ba, etc.): # # (.)(.) \2\1 # # Write a program to return with the last two characters of the # input! # TASK 2 # # Character sequences in bracket expression can be abbreviated # using character ranges separated by a hyphen character. # # For example, [a-z] matches every character between “a” and “z”, # [a-cx-z] matches letter a, b, c, x, y and z. # # Using this write a program to return with the first character # of the input, if that is between 1 and 5, or 9! # TASK 3 # # Bracket expression [^...] matches complementers of the # given characters or character ranges. For example, # [^01] matches every character, except 0 or 1. # # Write a program to return with the last two characters # of the input, if they don’t contain zeroes. # TASK 4 # # The pattern \d matches an arbitrary digit. For example # \d\d\d matches every 3-digit numbers. # # Using this, write a program to return with the first # three digits of the input! # TASK 5 # # Repetition sign + and * can be combined with bracket # expressions, \d and groups, too. There are three other # frequently used repetitions: # # ? 0, or 1 times # {n} exactly n times # {n,m} between n and m times # # For example, \d{6}, \d{1,3} # # Using this, write a program to do thousand separation # between 1 and 100,000,000,000. # # Rules: # # I. Separation is only from 5-digit numbers. # For example: 1, 10, 1000, 10,000. # # II. Separate by commas by 3-digit groups from the right side # For example: 100,000, 1000,000, 10,000,000, 100,000,000... # # NOTE: Test your program by typing a single number in the textbox “Input”. # OPTIONAL TASK 1 # # Groups can match different patterns: # # (word1|word2|word3) # # matches word1 OR word2 OR word3. # # For example, ([a-z]|10*) matches a single letter OR # 10 OR 100 OR 1000 etc. # # Groups can contain inner groups, too. # # Guess it, what does the following expression! # # ((Anne|Becky) (Smith|Johnson)) Full name: \1, First name: \2 # OPTIONAL TASK 2 # # References can be used within the regex # pattern (back references). # # Following program matches all 2-digit numbers # with repeating digits (11, 22, 33, 44 .. 99). # # (\d)\1 Cute number! 🙂 # # Extend this pattern for every numbers contain only repeating # digits (11, 22, ... 111... 555)! SCROLL DOWN FOR SOLUTIONS ⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩ # SOLUTION – TASK 1 # # .*(..) \1 # # or the less simple # # .*(.)(.) \1\2 # SOLUTION – TASK 2 # # ([1-59]).* \1 # SOLUTION – TASK 3 # # .*([^0][^0]) \1 # SOLUTION – TASK 4 # # (\d\d\d).* \1 # SOLUTION – TASK 5 # # NOTE: Last line will return with smaller and big numbers # without changes: # # (\d{2,3})(\d{3}) \1,\2 # (\d{1,3})(\d{3})(\d{3}) \1,\2,\3 # (\d{1,3})(\d{3})(\d{3})(\d{3}) \1,\2,\3,\4 # .* \0 # SOLUTION – OPTIONAL TASK 1 # ((Anne|Becky) (Smith|Johnson)) Full name: \1, First name: \2 # expression replaces this way: # # Anne Smith -> Full name: Anne Smith, First name: Anne # Becky Smith -> Full name: Becky Smith, First name: Becky # Anne Johnson -> Full name: Anne Johnson, First name: Anne # Becky Johnson -> Full name: Becky Johnson, First name: Becky # SOLUTION – OPTIONAL TASK 2 # # (\d)\1+ Cute number! 🙂 ####################################################### # CONGRATULATIONS – You have finished Tutorial Four! 🙂 #######################################################
# Soros Tutorial – Part Five 🚀 ... Go! # # We will complete the following number to English # number name conversion program, learning special # features of Soros programming language. 0 zero 1 one 2 two 3 three 4 four 5 five 6 six 7 seven 8 eight 9 nine 10 ten 11 eleven 12 twelve 13 thirteen # TASK 1 – Call me again! # # A Soros program is a single function, named $(). It’s # possible to call this function in the regex replacement # part with arbitrary text as an argument, and its return value # will be inserted in the regex replacement at the place of # the function call. # # In the following program line, the argument is “4”, # and function call “$(4)” is replaced with “four”, the # result of the call of function $ with the argument “4”: 14 $(4)teen # Extend the line 16 this way! 15 fifteen 16 # TASK 2 – Reference and call... # # We can use regex references in function arguments. # For example, we can describe 18 -> eighteen conversion # this way, too: 1(8) $(\1)een # Using the regex pattern \d (matching arbitrary digits), # give a *single* program line for 17 -> seventeen and # 19 -> nineteen conversion! (With this, line 14 and 16 # will be unnecessary, too.) # TASK 3 – Abbreviation of $(\n) is $n # # According to the title of this task, $1 means $(\1), # $2 means $(\2) etc. Rewrite the following program part to # use this abbreviated form! 20 twenty 2(\d) twenty-$(\1) # TASK 4 – Boundaries # # Soros programs have default automatic zero deletion in # its arguments, ie. $(1) or $(01) are equivalents. But # the following program line have a different problem for # the input number 100: after left zero deletion it still # remains a zero, resulting “one hundred zero” instead of # “one hundred”: 1(\d\d) one hundred $1 # The solution is using boundary dependent patterns. # These patterns can always match at the first run of the # Soros program, but at the next recursive calls, # matching depends from the position of the function call: # # ^pattern only matches, if the function call is there at # the beginning of the replacement. Example: # 1(\d) $1teen # # pattern$ only matches, if the function call is there at # the end of the replacement. Example: # 2(\d) twenty-$(\1) # # ^pattern$ only matches, if the function call is there at # the beginning and the end of the replacement. # Example: # 1(\d) $(ordinal |$1) # # NOTE: “|” before or after function calls sets explicite # boundary position. # # Correct the bug “one hundred zero” by using the # correct boundary sign on the program line “0 zero”, also # create a rule for negative numbers, to handle # “-0” -> “minus zero” conversion correctly! # TASK 5 – Deeper in recursion # # A recursive call can result further recursive calls, # allowing to break a complex problem into smaller parts, # or iterate a repeating task, as in the following # example. # # The first line of the following program uses the # boundary indicator $ to handle the originally 4-digit # or less numbers differently. What is the full program # doing with the other numbers? Try to answer, and # check it in a different IDE window! # # ^(\d{1,4})$ \1 # (\d+)(\d{3}) $1,\2 # .* \0 # TASK 6 – Optional text, depending from the return value # # Previously, we had a different program line for 20 and one # for 21–29 , because English uses a hyphen between the # number names. Using brackets around the recursive calls, # we can skip the first program line. The hyphen is only # added to “thirty”, if the return value of the recursive # function calls is not empty. 3(\d) thirty[-$(\1)] # Write a *single* program line to handle “sixty”, # “seventy” (60–79), and “ninety” (90–99)! # TASK 7 – Language-dependent program lines # # Using [:lang-code:] in a comment sets a # language-dependent program line. For example, # German number to number name rules # # 3(\d) [$1und]dreissig # [:de-CH:] # 3(\d) [$1und]dreißig # # result “dreissig” for the input “30”, if the language # of the conversion is de-CH (Swiss Standard German), # otherwise “dreißig”. # # It’s possible to use arbitrary number language codes # in the same program line. # # In Australia, Great Britain, Ireland and New Zealand, # 101 is “one hundred and one”, in other English speaking # countries, like USA and Canada, 101 is “one hundred one”. # Using the language codes en-AU, en-GB, en-IE and en-NZ # and the previous conditional text, describe number 100–999 # in both variants! # TASK 8 – More Functions # # In Soros language, there is only one real function, the $(), # but it’s possible to create function-like structures by using # prefixes. # # Numbertext.org language modules contain functions for # number to money conversion (“USD 2” -> “two U.S. dollars”), # number to ordinal name conversion (“2” -> “second”) and # ordinal-number conversion (“2” -> “2nd”). For example, # we can define ordinal numbers as follows: # # "ordinal 1" first # "ordinal 2" second # "ordinal 3" third # # According to the quotation marks, the regex patterns can # contain spaces, too. # # For the space separated prefixes, there is a default left # zero deletion, i.e. $(ordinal 1) is equivalent of # $(ordinal 001), so program line # # "ordinal 1(\d\d)" one hundred $(ordinal \1) # # works also for the input 101, 102 etc. correctly using # only the previous program lines. # # Other method of ordinal number conversion is to convert the # input to the default cardinal number names, and modifying # their text: # # "ordinal (\d+)" $(ordinal |$1) # "ordinal (.*)one" \1first # "ordinal (.*)two" \1second # # NOTE: As can be seen, it’s possible to embed function # calls within function calls, too. # # What can be the last program line of this function? # TASK 9 – Prefix “macros” # # Prefix macros simplify prefix handling. We can define # the previous ordinal function as follows, too # (see “ordinal” between double equal signs): # # == ordinal == # # ^0 zeroth # 1 first # 2 second # 3 third # # because this will be expanded in the following form: # # "^ordinal 0" zeroth # "ordinal 1" first # "ordinal 2" second # "ordinal 3" third # # With the other method, converting cardinal number names, # and later to ordinal ones: # # == ordinal == # # (\d+) $(ordinal |$1) # (.*)one \1first # (.*)two \1second # ... # (.*) \1th # # How is this expanded? # TASK 10 – Join Numbertext development! # # Your contribution will help LibreOffice and other free # softwares to support chapter numbering with number names, # converting money amounts to text (MONEYTEXT), creating # plural forms of money amounts and support better # title casing. # # Check and fix Soros code of your language on # http://NUMBERTEXT.org, or if there is no such module yet, # create it, based on the currency code of the # English or the more flexible Swedish (sv.sor) # modules! SCROLL DOWN FOR SOLUTIONS ⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩⇩ # SOLUTION – TASK 1–7 (for TASK 5, see next SOLUTION) # # Solutions marked as TASK 1–7 in comments: # # ^0 zero # TASK 4 # 1 one # 2 two # 3 three # 4 four # 5 five # 6 six # 7 seven # 8 eight # 9 nine # 10 ten # 11 eleven # 12 twelve # 13 thirteen # # 14 $(4)teen # 15 fifteen # # 16 $(6)teen # TASK 1 # 18 eighteen # 1(\d) $1teen # TASK 2 # 20 twenty # 2(\d) twenty-$1 # TASK 3 # 3(\d) thirty[-$1] # 4(\d) forty[-$1] # 5(\d) fifty[-$1] # 8(\d) eighty[-$1] # (\d)(\d) $1ty[-$2] # TASK 5 # # # separator function # :0+ # one million # :0*\d?\d " and " # one million and twenty-two # :\d+ ", " # one million, one thousand # # (\d)(\d\d) $1 hundred[ and $2] # one hundred and one [:en-AU:] [:en-GB:] [:en-IE:] [:en-NZ:] # TASK 6 # (\d)(\d\d) $1 hundred[ $2] # default: one hundred one # TASK 6 # (\d{1,2})([1-9]\d\d) $1 thousand[ $2] # ten thousand two hundred # (\d{1,3})(\d{3}) $1 thousand$(:\2)$2 # one hundred thousand, two hundred # (\d{1,3})(\d{6}) $1 million$(:\2)$2 # (\d{1,3})(\d{9}) $1 billion$(:\2)$2 # # # negative number # # [-−](\d+) negative |$1 # TASK 4 # # # decimals # # 0[.,] point # ([-−]?\d+)[.,] $1| point # ([-−]?\d+[.,]\d*)(\d) $1| |$2 # # # currency # # # unit/subunit singular/plural # # us:([^,]*),([^,]*),([^,]*),([^,]*) \1 # up:([^,]*),([^,]*),([^,]*),([^,]*) \2 # ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 # sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 # # AUD:(\D+) $(\1: Australian dollar, Australian dollars, cent, cents) # CAD:(\D+) $(\1: Canadian dollar, Canadian dollars, cent, cents) # CHF:(\D+) $(\1: Swiss franc, Swiss francs, centime, centimes) # CNY:(\D+) $(\1: Chinese yuan, Chinese yuan, fen, fen) # EUR:(\D+) $(\1: euro, euro, cent, cents) # GBP:(\D+) $(\1: pound sterling, pounds sterling, penny, pence) # JPY:(\D+) $(\1: Japanese yen, Japanese yen, sen, sen) # USD:(\D+) $(\1: U.S. dollar, U.S. dollars, cent, cents) # # "(JPY [-−]?\d+)[.,](\d\d)0" $1 # "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin # # "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) # "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) # # "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao # "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen # # "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 and |$(1)$(\2:ss) # "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 and |$(\030)$(\2:sp) # "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 and |$3$(\2:sp) # # == ordinal == # # # convert to text, and recall to convert # # cardinal names to ordinal ones # # ([-−]?\d+) $(ordinal |$1) # # (.*)one \1first # (.*)two \1second # (.*)three \1third # (.*)five \1fifth # (.*)eight \1eighth # (.*)nine \1ninth # (.*)twelve \1twelfth # (.*)y \1ieth # (.*) \1th # TASK 7 # # == ordinal-number == # # (.*1\d) \1th # (.*1) \1st # (.*2) \1nd # (.*3) \1rd # (.*) \1th # SOLUTION – TASK 5 # # This is a thousand separator # program extended for all numbers. # The middle line put a comma before # the last three digits, and do the # same for the remaining digits using # a recursive call, and in that a # next recursive call etc. # # ^(\d{1,4})$ \1 # (\d+)(\d{3}) $1,\2 # .* \0 # # For example, for the input “10000000” # the inner states of the calls: # # First call: $(10000),000 # Second call: $(10),000 # Third call: 10 # # resulting “10,000,000” in the end of # all returns. # SOLUTION – TASK 9 # # As before in TASK 8: # # "ordinal (\d+)" $(ordinal |$1) # "ordinal (.*)one" \1first # "ordinal (.*)two" \1second # ... # "ordinal (.*)" \1th ####################################################### # CONGRATULATIONS – You have finished Tutorial Five! 🙂 #######################################################
^0$ nul 1 een 2 twee 3 drie 4 vier 5 vyf 6 ses 7 sewe 8 agt 9 nege 10 tien 11 elf 12 twaalf 13 dertien 14 veertien 17 sewentien 18 agtien 19 negentien 1(\d) $1|tien 20 twintig 30 dertig 40 veertig 70 sewentig 80 tagtig 90 negentig (\d)0 $1tig (\d)(\d) $2-en-$(\10) # function a a:0* " " # eenhonderd a:0*1?\d -en- # eenhonderd-en-een a:0*\d0 -en- # eenhonderd-en-twintig a:\d+ " " # eenhonderd een-en-twintig # function b b:0*1?\d # negentienduisend b:0*\d0 # twintigduisend b:\d+ " " # een-en-twintig duisend ^1(\d\d) honderd$(a:\1)$1 (\d)(\d\d) $1honderd$(a:\2)$2 ^1(\d{3}) duisend$(a:\1)$1 (\d{1,3})(\d{3}) $1$(b:\1)duisend$(a:\2)$2 (\d{1,3})(\d{6}) $1$(b:\1)miljoen$(a:\2)$2 (\d{1,3})(\d{9}) $1$(b:\1)miljard$(a:\2)$2 (\d{1,3})(\d{12}) $1$(b:\1)biljoen$(a:\2)$2 (\d{1,3})(\d{15}) $1$(b:\1)biljard$(a:\2)$2 (\d{1,3})(\d{18}) $1$(b:\1)triljoen$(a:\2)$2 (\d{1,3})(\d{21}) $1$(b:\1)triljard$(a:\2)$2 # negative number [-−](\d+) min |$1 # decimals ([-−]?\d+)[.,] $1| komma ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currencies # unit/subunit u:([^,]*),([^,]*),([^,]*) \1 s:([^,]*),([^,]*),([^,]*) \2 p:([^,]*),([^,]*),([^,]*) \3 CHF:(.) $(\1: Zwitserse franc, centime, centimes) CNY:(.) $(\1: renminbi yuan, fen, fen) EUR:(.) $(\1: euro, cent, cent) GBP:(.) $(\1: pond sterling, penny, pence) JPY:(.) $(\1: yen, sen, sen) USD:(.) $(\1: Amerikaanse dollar, sent, sent) ZAR:(.) $(\1: rand, sent, sent) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?0)([.,]00?)?" nul$(\1:u) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 een$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:p) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:p) == ordinal == ([-−]?([24-6]|\d*1\d|\d+0[24-6])) $1|de ([-−]?([79]|\d+0[79])) $1|nde ([-−]?\d+) $(ordinal |$1) (.*)een \1eerste (.*)drie \1derde (.*) \1ste == ordinal-number == ([-−]?([2-79]|\d*1\d|\d+0[2-79])) \1de ([-−]?\d+) \1ste == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
# 0-135;200;205;210;211;231;300;400;405;410;411;420;431;500;600;700;800;900;1000;1015;1030;1031;1100;1101;1120;1121;1200;2000;2001;2020;2021;2100;2101;2120;2121;10000;11000;11001;11020;11021;11100;11101;11120;11121;20000;21000;21001;21020;21021;21200;21201;21220;21221;22000;100000;300000;300001;310000;321000;321321;1000000;1000001;1000023;4000435;11320387;34045671940;1.1;1.2;2,01;2.21;2.22;2.222;2,2222;45,9876543;-5;−17,48 ^0 нула 1 едно 2 две 3 три 4 четири 5 пет 6 шест 7 седем 8 осем 9 девет 10 десет 11 единадесет 12 дванадесет 1([0-9]) $1надесет ([0-9])([0-9]) $(m:$1)десет[ и $2] ([0-9])([0-9][0-9]) $(e2:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{3}) $(e3:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{6}) $(e6:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{9}) $(e9:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{12}) $(e12:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{15}) $(e15:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{18}) $(e18:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{21}) $(e21:\1)[ $(and:$2)] ([0-9]{1,3})([0-9]{24}) $(e24:\1)[ $(and:$2)] e2:1 сто e2:([23]) $1ста e2:([0-9]) $1стотин e3:1 хиляда e3:([0-9]{1,3}) $(f:$1) хиляди e6:1 един милион e6:([0-9]{1,3}) $(m:$1) милиона e9:1 един милиард e9:([0-9]{1,3}) $(m:$1) милиарда e12:1 един трилион e12:([0-9]{1,3}) $(m:$1) трилиона e15:1 един квадрилион e15:([0-9]{1,3}) $(m:$1) квадрилиона e18:1 един квинтилион e18:([0-9]{1,3}) $(m:$1) квинтилиона e21:1 един секстилион e21:([0-9]{1,3}) $(m:$1) секстилиона e24:1 един септилион e24:([0-9]{1,3}) $(m:$1) септилиона # prepend "и" ("and") only to a subphrase that does not already contain it "and:([а-я ]+ и [^0-9]+)" \1 "and:([^0-9]+)" и \1 # negative number [-−]([0-9]+) минус |$1 # decimals by_digits:([0-9])([0-9]*) $1 $(by_digits:\2) ([-−]?[0-9]+)[.,] цяло ([-−]?[0-9]+)[.,]1 $1 цяло и една десета ([-−]?[0-9]+)[.,]([0-9]) $1 цяло и $(f:|$2) десети ([-−]?[0-9]+)[.,]01 $1 цяло и една стотна ([-−]?[0-9]+)[.,]([0-9][0-9]) $1 цяло и $(f:|$2) стотни ([-−]?[0-9]+)[.,]001 $1 цяло и една хилядна ([-−]?[0-9]+)[.,]([0-9]{3}) $1 цяло и $(f:|$2) хилядни ([-−]?[0-9]+)[.,]0001 $1 цяло и една десетохилядна ([-−]?[0-9]+)[.,]([0-9]{4}) $1 цяло и $(f:|$2) десетохилядни ([-−]?[0-9]+)[.,]00001 $1 цяло и една стохилядна ([-−]?[0-9]+)[.,]([0-9]{5}) $1 цяло и $(f:|$2) стохилядни ([-−]?[0-9]+)[.,]000001 $1 цяло и една милионна ([-−]?[0-9]+)[.,]([0-9]{6}) $1 цяло и $(f:|$2) милионни ([-−]?[0-9]+)[.,]([0-9]+) $1 цяло и $(by_digits:\2) # gender conversion for cardinals (default is neuter) n:([^0-9]+) \1 f:([^0-9]*)едно \1една f:([^0-9]+) \1 m:([^0-9]*)едно \1един m:([^0-9]*)две \1два m:([^0-9]+) \1 # currency # unit/subunit singular/plural us(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \2 up(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \3 ss.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \4 sp.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \5 BGN:(.+),(.+) $(\2mf:лев,лева,стотинка,стотинки,\1) CHF:(.+),(.+) $(\2mm:швейцарски франк,швейцарски франка,сантим,сантима,\1) CNY:(.+),(.+) $(\2mm:юан,юана,фен,фена,\1) EUR:(.+),(.+) $(\2nm:евро,евро,цент,цента,\1) GBP:(.+),(.+) $(\2fm:британска лира,британски лири,пенс,пенса,\1) JPY:(.+),(.+) $(\2fm:йена,йени,сен,сена,\1) RUB:(.+),(.+) $(\2ff:рубла,рубли,копейка,копейки,\1) TRY:(.+),(.+) $(\2fm:турска лира,турски лири,куруш,куруша,\1) USD:(.+),(.+) $(\2mm:щатски долар,щатски долара,цент,цента,\1) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $(\1:|$2,us) "([A-Z]{3}) ([-−]?[0-9]+)([.,]00?)?" $(\1:|$2,up) "(([A-Z]{3}) [-−]?[0-9]+)[.,](01)" $1 и $(\2:|$3,ss) "(([A-Z]{3}) [-−]?[0-9]+)[.,]([0-9])" $1 и $(\2:|$(\30),sp) "(([A-Z]{3}) [-−]?[0-9]+)[.,]([0-9][0-9])" $1 и $(\2:|$3,sp) == neuter == ([-−]?[0-9]+) $1 == masculine == ([-−]?[0-9]+) $(m:|$1) == feminine == ([-−]?[0-9]+) $(f:|$1) == ordinal == # up to 6 digits, more than enough for outline numbering 0 нулев 1 първи 2 втори 3 трети 4 четвърти 5 пети 6 шести 7 седми 8 осми 9 девети (1[0-9]|[2-9]0) $1и ([0-9])([0-9]) $(\10)[ и $(ordinal \2)] 100 стотен ([23])00 $1стен ([0-9])00 $1стотен ([0-9])([0-9][0-9]) $(\100) $(and:$(ordinal \2)) 1000 хиляден (1?[0-9]|[1-9]00?)000 $(f:|$1)хиляден ([0-9]{2,3})000 $(f:|$1) хиляден 1([0-9]{3}) хиляда[ $(and:$(ordinal \1))] ([0-9]{1,3})([0-9]{3}) $(f:|$1) хиляди[ $(and:$(ordinal \2)]) [-−]([0-9]+) минус $(ordinal \1) == ordinal-masculine == ([-−]?[0-9]+) $(ordinal \1) == ordinal-feminine == ([-−]?[0-9]+) $(ordinal-feminine $(ordinal \1)) ([^0-9]+)ен \1на ([^0-9]+)и \1а ([^0-9]+) \1а == ordinal-neuter == ([-−]?[0-9]+) $(ordinal-neuter $(ordinal \1)) ([^0-9]+)ен \1но ([^0-9]+)и \1о ([^0-9]+) \1о == ordinal-number == ([0-9]+) \1. == help == "" $(1)|, $(2), $(3)\n$(\0 masculine)$(\0 feminine)$(\0 neuter)$(\0 ordinal-masculine)$(\0 ordinal-feminine)$(\0 ordinal-neuter)$(\0 ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 zero 1$ u 1 un 2 dos 3 tres 4 quatre 5 cinc 6 sis 7 set 8 vuit 9 nou 10 deu 11 onze 12 dotze 13 tretze 14 catorze 15 quinze 16 setze 17 disset 1(\d) di$1 20 vint 2(\d) vint-i-$1 30 trenta 40 quaranta 50 cinquanta 60 seixanta 70 setanta 80 vuitanta 90 noranta (\d)(\d) $(\10)-$2 1(\d\d) cent[ $1] (\d)(\d\d) $1-cents[ $2] 1(\d{3}) mil[ $1] (\d{1,3})(\d{3}) $1 mil[ $2] 1(\d{6}) un milió[ $1] (\d{1,6})(\d{6}) $1 milions[ $2] 1(\d{9}) mil milions[ $1] 1(\d{12}) un bilió[ $1] (\d{1,6})(\d{12}) $1 bilions[ $2] 1(\d{18}) un trilió[ $1] (\d{1,6})(\d{18}) $1 trilions[ $2] 1(\d{24}) un quadrilió[ $1] (\d{1,6})(\d{24}) $1 quadrilions[ $2] # negative number [-−](\d+) menys |$1 # decimals "([-−]?\d+)[.,]" |$1| coma "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # convert masculine to feminine f:(.*ili)(.*) \1$(f:\2) # convert only <1000000 f:(.*u)n([^a].*|$) $(f:\1na\2) # un -> una f:(.*d)o(s.*) $(f:\1ue\2) # dos -> dues f:(.*cent)(s.*) $(f:\1e\2) # cents -> centes .:(.*) \1 # unit/subunit singular/plural # million or greater part of the number name separated by "ili" pattern # before masculine to feminine conversion us(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\7) \2 up(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\7) \3 ud(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\7) \4 ss.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\7) \5 sp.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\7) \6 # "mm" means masculine unit and masculine subunit # Usually used by Catalan users CHF:(.+),(.+) $(\2mm: franc suís, francs suïssos, de francs suïssos, cèntim, cèntims, \1) EUR:(.+),(.+) $(\2mm: euro, euros, d'euros, cèntim, cèntims, \1) GBP:(.+),(.+) $(\2fm: lliura esterlina, lliures esterlines, de lliures esterlines, penic, penics, \1) JPY:(.+),(.+) $(\2mm: ien, iens, de iens, sen, sen, \1) USD:(.+),(.+) $(\2mm: dòlar EUA, dòlars EUA, de dòlars EUA, centau, centaus, \1) # ACTIVE ISO 4217 CODES--A-- AED:(.+),(.+) $(\2mm: dírham dels Emirats Àrabs Units, dírhams dels Emirats Àrabs Units, de dírhams dels Emirats Àrabs Units, fils, fulús, \1) AFN:(.+),(.+) $(\2mm: afgani, afganis, d'afganis, puli, puli, \1) ALL:(.+),(.+) $(\2mm: lek, lekë, de lekë, qindarka, qindarka, \1) AMD:(.+),(.+) $(\2mm: dram, drams, de drams, luma, luma, \1) ANG:(.+),(.+) $(\2mm: florí de les Antilles Neerlandeses, florins de les Antilles Neerlandeses, de florins de les Antilles Neerlandeses, cèntim, cèntims, \1) AOA:(.+),(.+) $(\2fm: kwanza, kwanzes, de kwanzes, cèntim cèntims, \1) ARS:(.+),(.+) $(\2mm: peso argentí, pesos argentins, de pesos argentins, centau, centaus, \1) AUD(.+),(.+) $(\2mm: dòlar australià, dòlars australians, de dòlars australians, centau, centaus, \1) AWG:(.+),(.+) $(\2mm: florí d'Aruba, florins d'Aruba, de florins d'Aruba, cèntim, cèntims, \1) AZN:(.+),(.+) $(\2mm: manat azerbaidjanès, manats azerbaidjanesos, de manats azerbaidjanesos, qəpik, qəpik, \1) # ACTIVE ISO 4217 CODES --X-- #XAF Franc CFA emès pel BEAC (Banc dels Estats de l'Àfrica Central) XAG:(.+),(.+) $(\2fm: unça de plata, unces de plata, d'unces de plata, cèntim, cèntims, \1) XAU:(.+),(.+) $(\2fm: unça d'or, unces d'or, d'unces d'or, cèntim, cèntims, \1) #XBA Unitat compensatòria europea (EURCO) (unitat per al mercat d'obligacions) #XBB Unitat monetària europea (EMU-6) (unitat per al mercat d'obligacions) #XBC Unitat de compte europea 9 (EUA-9) (unitat per al mercat d'obligacions) #XBD Unitat de compte europea 17 (EUA-17) (unitat per al mercat d'obligacions) #XCD Dòlar del Carib Oriental #XDR Drets especials de gir (del Fons Monetari Internacional) #XFU Franc UIC (divisa especial) #XOF Franc CFA emès pel BCEAO (Banc Central dels Estats de l'Àfrica Occidental) XPD:(.+),(.+) $(\2fm: unça de pal·ladi, unces de pal·ladi, d'unces de pal·ladi, cèntim, cèntims, \1) #XPF Franc CFP (per als territoris francesos del Pacífic) XPT:(.+),(.+) $(\2fm: unça de platí, unces de platí, d'unces de platí, cèntim, cèntims, \1) #XTS Codi reservat per a proves #XXX Sense moneda, sense transacció monetària # OBSOLETE ISO 4217 CODES --Replaced by EUR-- ADF:(.+),(.+) $(\2mm: franc andorrà, francs andorrans, de francs andorrans, cèntim, cèntims, \1) ADP:(.+),(.+) $(\2fm: pesseta andorrana, pessetes andorranes, de pessetes andorranes, cèntim, cèntims, \1) ATS:(.+),(.+) $(\2mm: xíling austríac, xílings austríacs, de xílings austríacs, groschen, groschen, \1) BEF:(.+),(.+) $(\2mm: franc belga, francs belgues, de francs belgues, cèntim, cèntims, \1) CYP:(.+),(.+) $(\2mm: lliura xipriota, lliures xipriotes, de lliures xipriotes, cèntim, cèntims, \1) DEM:(.+),(.+) $(\2mm: marc alemany, marcs alemanys, de marcs alemanys, penic, penics, \1) ESP:(.+),(.+) $(\2fm: pesseta, pessetes, de pessetes, cèntim, cèntims, \1) FIM:(.+),(.+) $(\2mm: marc finlandès, marcs finlandesos, de marcs finlandesos, penic, penics, \1) FRF:(.+),(.+) $(\2mm: franc francès, francs francesos, de francs francesos, cèntim, cèntims, \1) GRD:(.+),(.+) $(\2fm: dracma grega, dracmes gregues, leptó, leptà, \1) IEP:(.+),(.+) $(\2fm: lliura irlandesa, lliures irlandeses, de lliures irlandeses, penic, penics, \1) ITL:(.+),(.+) $(\2fm: lira italiana, lires italianes, de lires italianes, cèntim, cèntims, \1) LUF:(.+),(.+) $(\2mm: franc luxemburguès, francs luxemburguesos, de francs luxemburguesos, cèntim, cèntims, \1) MCF:(.+),(.+) $(\2mm: franc monegasc, francs monegascs, de francs monegascs, cèntim, cèntims, \1) MTL:(.+),(.+) $(\2fm: lira maltesa, lires malteses, de lires malteses, cèntim, cèntims, \1) NLG:(.+),(.+) $(\2mm: florí neerlandès, florins neerlandesos, de florins neerlandesos, cèntim, cèntims, \1) PTE:(.+),(.+) $(\2mm: escut portuguès, escuts portuguesos, de escuts portuguesos, centau, centaus, \1) SIT:(.+),(.+) $(\2mm: tolar eslovè, tolars eslovens, de tolars eslovens, stotin, stotinov, \1) SKK:(.+),(.+) $(\2fm: corona eslovaca, corones eslovaques, de corones eslovaques, halier, halierov, \1) SML:(.+),(.+) $(\2fm: lira de San Marino, lires de San Marino, de lires de San Marino, cèntim, cèntims, \1) VAL:(.+),(.+) $(\2fm: lira vaticana, lires vaticanes, de lires vaticanes, cèntim, cèntims, \1) XEU:(.+),(.+) $(\2mm: ecu, ecus, d'ecus, cèntim, cèntims, \1) "([A-Z]{3}) ([-−]?[01])([.,]00?)?"$(\1:|$2,us) "([A-Z]{3}) ([-−]?\d+0{6,})([.,]00?)?"$(\1:|$2,ud) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(\1:|$2,up) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 amb$(\2:un,ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 amb$(\2:|$(\30),sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 amb$(\2:|$3,sp) == feminine == 1 una (.*) $(f:|$1) == masculine == 1 un (.*) $1 == ordinal(-masculine)? == 1 primer 2 segon ([-−]?\d+) $(ordinal |$2) (.*)nou \2novè (.*)deu \2desè (.*-)u(na?)? \2unè "(.* )u(na?)?" \2 primer "(.* )dos" \2segon "(.* t|t)res" \2ercer "(.* q|q)uatre" \2uart (.*)cinc \2cinquè (.*)[ae] \2è (.*(cent|mil|ion))s? \2è (.*li)ó \2onè (.*) \2è == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal-masculine \1)) (.*)è \1ena (.*) \1a == (ordinal)-number(-feminine|-masculine)? == ([-−]?\d+) \3$(ordinal-number $(\1\2 \3)) .*(.) \3 == help == "" $(1)|, $(2), $(3)\n$(help feminine)$(help masculine)$(help ordinal-number-masculine)$(help ordinal-number-feminine)$(help ordinal-feminine)$(help ordinal-masculine) (feminine|masculine|ordinal(-number)?(-feminine|-masculine)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 nula 1 jedna 2 dva ^2$ dvě 3 tři 4 čtyři 5 pět 6 šest 7 sedm 8 osm 9 devět 10 deset 11 jedenáct 14 čtrnáct 15 patnáct 19 devatenáct 1(\d) $1náct ([234])(\d) $1cet[ $2] 5(\d) padesát[ $1] 6(\d) šedesát[ $1] 9(\d) devadesát[ $1] (\d)(\d) $1desát[ $2] 1(\d\d) sto[ $1] 2(\d\d) dvě stě[ $1] ([34])(\d\d) $1 sta[ $2] (\d)(\d\d) $1 set[ $2] 1(\d\d\d) tisíc[ $1] ([234])(\d\d\d) $1 tisíce[ $2] (\d{1,3})(\d\d\d) $1 tisíc[ $2] 1(\d{6}) milión[ $1] ([234])(\d{6}) $1 milióny[ $2] (\d{1,3})(\d{6}) $1 miliónů[ $2] 1(\d{9}) miliarda[ $1] ([234])(\d{9}) $1 miliardy[ $2] (\d{1,3})(\d{9}) $1 miliard[ $2] 1(\d{12}) bilión[ $1] ([234])(\d{12}) $1 bilióny[ $2] (\d{1,3})(\d{12}) $1 biliónů[ $2] 1(\d{15}) biliarda[ $1] ([234])(\d{15}) $1 biliardy[ $2] (\d{1,3})(\d{15}) $1 biliard[ $2] 1(\d{18}) trilion[ $1] ([234])(\d{18}) $1 trilióny[ $2] (\d{1,3})(\d{18}) $1 triliónů[ $2] 1(\d{21}) triliarda[ $1] ([234])(\d{21}) $1 triliardy[ $2] (\d{1,3})(\d{21}) $1 triliard[ $2] 1(\d{24}) kvadrilión[ $1] ([234])(\d{24}) $1 kvadrilióny[ $2] (\d{1,3})(\d{24}) $1 kvadriliónů[ $2] # negative number [-−](\d+) minus |$1 # decimals ([-−]?\d+)[.,] $1| čárka ([-−]?\d+[.,])([^0]\d) $1| |$2 ([-−]?\d+[.,])(\d)(\d)(\d) $1| |$2 |$3 |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular / plural / plural genitiv us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 ugender:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \7 sgender:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \8 CHF:(\D+) $(\1: švýcarský frank, švýcarské franky, švýcarských franků, centim, centimy, centimů,masculine,masculine) CNY:(\D+) $(\1: jüan, jüany, jüanů, fen, feny, fenů,masculine,masculine) CZK:(\D+) $(\1: koruna česká, koruny české, korun českých, haléř, haléře, haléřů,feminine,masculine) EUR:(\D+) $(\1: euro, eura, eur, cent, centy, centů,neuter,masculine) GBP:(\D+) $(\1: libra šterlinků, libry šterlinků, liber šterlinků, pence, pence, pencí,feminine,feminine) JPY:(\D+) $(\1: jen, jeny, jenů, sen, seny, senů,masculine,masculine) RUB:(\D+) $(\1: rubl, rubly, rublů, kopějka, kopějky, kopějek,masculine,feminine) SKK:(\D+) $(\1: slovenská koruna, slovenské koruny, slovenských korun, haléř, haléře, haléřů,feminine,masculine) USD:(\D+) $(\1: americký dolar, americké dolary, amerických dolarů, cent, centy, centů,masculine,masculine) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:us) "([A-Z]{3}) ([-−]?[2-4])([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:ug) "(CNY [-−]?\d+)[.,]10?" $1 $(cardinal-neuter 1) ťiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $(cardinal-neuter \2) ťiao "((CNY) [-−]?\d+[.,]\d)1" $1 $(cardinal-masculine 1)$(\2:ss) "((CNY) [-−]?\d+[.,]\d)(2|3|4)" $1 $(cardinal-masculine \3)$(\2:sp) "((CNY) [-−]?\d+[.,]\d)(\d)" $1 $(cardinal-masculine \3)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](00)" $1 $(cardinal-$(\2:sgender) \1)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 $(cardinal-$(\2:sgender) \3)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](02|03|04)" $1 $(cardinal-$(\2:sgender) \3)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $(cardinal-$(\2:sgender) \3)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(cardinal-$(\2:sgender) \30)$(\2:sg) == cardinal-neuter == 1 jedno 2 dvě (.*) $1 == cardinal-feminine == 1 jedna 2 dvě (.*) $1 == cardinal-masculine == 1 jeden (.*) $1 == ordinal == ([-−]?\d+) $(ordinal |$1) "(.*)dvě stě(.*)" $(ordinal \1dvoustý\2) "(.*)tři sta(.*)" $(ordinal \1třístý\2) "(.*)čtyři sta(.*)" $(ordinal \1čtyřstý\2) "(.*)(pět|šest|sedm|osm) set(.*)" $(ordinal \1\2istý\3) "(.*)devět set(.*)" $(ordinal \1devítistý\2) nula nultý (.*)(jedno|jedna|jeden) $(ordinal \1první) (.*)(jedenáct) $(ordinal \1jedenáctý) (.*)(dva|dvě) $(ordinal \1druhý) (.*)(dvě|dva)\b(.*) $(ordinal \1druhý\3) (.*)tři\b(.*) $(ordinal \1třetí\2) (.*)čtyři\b(.*) $(ordinal \1čtvrtý\2) (.*)pět\b(.*) $(ordinal \1pátý\2) "(.*)(šest|sedm|osm|desát|náct|sát)( .+|$)" $(ordinal \1\2ý\3) (.*)devět\b(.*) $(ordinal \1devátý\2) "(.*)(c|s)et\b(.*)" $(ordinal \1\2átý\3) (.*)sto\b(.*) $(ordinal \1stý\2) (.*)tisíce?(.*) \1tisící\2 (.*)milión[yů]?(.*) \1milióntý\2 (.*)miliard[ay]?(.*) \1miliardtý\2 (.*) \1 == ordinal-masculine == (.*) $(ordinal |$1) == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine |$(ordinal-masculine \1)) (.*)ý(.*) $(ordinal-feminine \1á\2) (.*) \1 == ordinal-neuter == ([-−]?\d+) $(ordinal-neuter |$(ordinal-masculine \1)) (.*)ý(.*) $(ordinal-neuter \1é\2) (.*) \1 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-neuter)$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal)$(help ordinal-masculine)$(help ordinal-feminine)$(help ordinal-neuter)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 nul 1$ en 1 et 2 to 3 tre 4 fire 5 fem 6 seks 7 syv 8 otte 9 ni 10 ti 11 elleve 12 tolv 13 tretten 14 fjorten 15 femten 16 seksten 17 sytten 18 atten 19 nitten 20 tyve 30 tredive 40 fyrre 50 halvtreds 60 tres 70 halvfjerds 80 firs 90 halvfems (\d)(\d) $2|og$(\10) (\d)(\d\d) $1 hundrede[ og $2] (\d{1,3})(\d{3}) $1 tusind[ og $2] a:1,0+ a:\d+,0+ er a:1,(\d+) " og $1" a:\d+,(\d+) "er og $1" (\d{1,3})(\d{6}) $1| million$(a:\1,\2) (\d{1,3})(\d{9}) $1| milliard$(a:\1,\2) (\d{1,3})(\d{12}) $1| billion$(a:\1,\2) (\d{1,3})(\d{15}) $1| billiard$(a:\1,\2) (\d{1,3})(\d{18}) $1| trillion$(a:\1,\2) (\d{1,3})(\d{21}) $1| trilliard$(a:\1,\2) (\d{1,3})(\d{24}) $1| kvadrillion$(a:\1,\2) # negative number [-−](\d+) minus |$1 # decimals ([-−]?\d+)[.,] $1| komma "([-−]?\d+[.,]0*)(\d+)" $1 |$2 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: schweizisk franc, schweizisk franc, centime, centimes) CNY:(\D+) $(\1: renminbi yuan, renminbi yuan, fen, fen) DKK:(\D+) $(\1: dansk krone, danske kroner, øre, øre) EUR:(\D+) $(\1: euro, euro, cent, cent) GBP:(\D+) $(\1: pund sterling, pund sterling, penny, pence) ISK:(\D+) $(\1: islandsk krone, islandske kroner, eyrir, aurar) JPY:(\D+) $(\1: yen, yen, sen, sen) SEK:(\D+) $(\1: svensk krone, svenske kroner, öre, öre) USD:(\D+) $(\1: US dollar, US dollar, cent, cent) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sp) == ordinal == ([-−]?\d+) $(ordinal |$1) nul nulte # 0 en først # 1 "(.*) en" \1 først # 1 (.*)to \1anden # 2 (.*)tre \1tredje # 3 (.*)fire \1fjerde # 4 (.*(fem|ellev|tolv|ard|on))(e|er)? \1te # 5, 11, 12, 10^6, 10^9 etc. (.*)seks \1sjette # 6 (.*)tres \1tressende # 60 (.*(syv|ott|ni|ti|tyv|trediv|fyrr|s))e? \1ende # 7, 8, 9, 10, 20, 30, 40, 50, 70, 80, 90 (.*en) \1de # 13-19 (.*tusind) \1e # 1000 etc. (.*) \1 # 100, etc. == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0$ null 1$ eins 1 ein 2 zwei 3 drei 4 vier 5 fünf 6 sechs 7 sieben 8 acht 9 neun 10 zehn 11 elf 12 zwölf 16 sechzehn 17 siebzehn 1(\d) $1zehn 2(\d) [$1und]zwanzig 3(\d) [$1und]dreissig # [:de-CH:] [:de-LI:] 3(\d) [$1und]dreißig 6(\d) [$1und]sechzig 7(\d) [$1und]siebzig (\d)(\d) [$2und]$1zig (\d)(\d\d) $1hundert$2 (\d{1,3})(\d{3}) $1tausend$2 1(\d{6}) eine Million[ $1] (\d{1,3})(\d{6}) $1 Millionen[ $2] 1(\d{9}) eine Milliarde[ $1] (\d{1,3})(\d{9}) $1 Milliarden[ $2] 1(\d{12}) eine Billion[ $1] (\d{1,3})(\d{12}) $1 Billionen[ $2] 1(\d{15}) eine Billiarde[ $1] (\d{1,3})(\d{15}) $1 Billiarden[ $2] 1(\d{18}) eine Trillion[ $1] (\d{1,3})(\d{18}) $1 Trillionen[ $2] 1(\d{21}) eine Trilliarde[ $1] (\d{1,3})(\d{21}) $1 Trilliarden[ $2] # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| Komma "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: Schweizer Franken, Schweizer Franken, Rappen, Rappen) CNY:(\D+) $(\1: Yuan, Yuan, Fen, Fen) EUR:(\D+) $(\1: Euro, Euro, Cent, Cent) GBP:(\D+) $(\1: Pfund Sterling, Pfund Sterling, Penny, Pence) USD:(\D+) $(\1: US-Dollar, US-Dollar, Cent, Cents) "JPY ([-−]?\d+([.,]\d+)?)" $1 Yen "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,]10?" $1 $2 Jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 Jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 Fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 Fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 und $(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 und $(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 und $3$(\2:sp) == ordinal == ([-−]?[024569]) $1te ([-−]?\d*0[24569]) $1te ([-−]?\d*1\d) $1te ([-−]?\d+) $(ordinal $1) (.*)eins \1erste (.*)drei \1dritte (.*)sieben \1siebte (.*)acht \1achte "(.*)eine Milli(on|ard)e?" \1einmilli\2ste "(.*)eine Billi(on|ard)e?" \1einbilli\2ste "(.*)eine Trilli(on|ard)e?" \1eintrilli\2ste "(.*) Milli(on|ard)en" \1milli\2ste "(.*) Billi(on|ard)en" \1billi\2ste "(.*) Trilli(on|ard)en" \1trilli\2ste (.*) \1ste == ordinal-number == (\d+) \1. == year == (10)([0-9][0-9]) tausend$2 (1[1-9])([0-9][0-9]) $1hundert$2 (.*) $1 == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 μηδέν 1 ένα 2 δύο 3 τρία 4 τέσσερα 5 πέντε 6 έξι 7 επτά 8 οκτώ 9 εννέα 10 δέκα 11 έντεκα 12 δώδεκα 1(\d) δεκα$1 2(\d) είκοσι[ $1] 3(\d) τριάντα[ $1] 4(\d) σαράντα[ $1] 5(\d) πενήντα[ $1] 6(\d) εξήντα$1 7(\d) εβδομήντα[ $1] 8(\d) ογδόντα[ $1] 9(\d) ενενήντα[ $1] 1(\d\d) εκατό[v $1] 2(\d\d) διακόσια[ $1] 3(\d\d) τριακόσια[ $1] 4(\d\d) τετρακόσια[ $1] 5(\d\d) πεντακόσια[ $1] 6(\d\d) εξακόσια[ $1] 7(\d\d) επτακόσια[ $1] 8(\d\d) οκτακόσια[ $1] 9(\d\d) εννιακόσια[ $1] 1(\d{3}) χίλια[ $1] (\d{1,3})(\d{3}) $(cardinal-feminine \1) χιλιάδες[ $2] 1(\d{6}) ένα εκατομμύριο[ $1] (\d{1,3})(\d{6}) $1 εκατομμύρια[ $2] 1(\d{9}) ένα δισεκατομμύριο[ $1] (\d{1,3})(\d{9}) $1 δισεκατομμύρια[ $2] 1(\d{12}) ένα τρισεκατομμύριο[ $1] (\d{1,3})(\d{12}) $1 τρισεκατομμύρια[ $2] 1(\d{15}) ένα τετράκις εκατομμύριο[ $1] (\d{1,3})(\d{15}) $1 τετράκις εκατομμύρια[ $2] 1(\d{18}) ένα πεντάκις εκατομμύριο[ $1] (\d{1,3})(\d{18}) $1 πεντάκις εκατομμύρια[ $2] 1(\d{21}) ένα εξάκις εκατομμύριο[ $1] (\d{1,3})(\d{21}) $1 εξάκις εκατομμύρια[ $2] 1(\d{24}) ένα επτάκις εκατομμύριο[ $1] (\d{1,3})(\d{24}) $1 επτάκις εκατομμύρια[ $2] # negative number [-−](\d+) μείον |$1 # decimals "([-−]?\d+)[.,]" "$1| κόμμα" "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: ελβετικό φράγκο, ελβετικό φράγκο, σαντίμ, σαντίμ) GBP:(\D+) $(\1: λίρα στερλίνα, λίρα στερλίνα, πέννα, πένες) JPY:(\D+) $(\1: γιεν, γιεν, σεν, σεν) EUR:(\D+) $(\1: ευρώ, ευρώ, λεπτό, λεπτά) USD:(\D+) $(\1: δολάριο ΗΠΑ, δολαρίων ΗΠΑ, σεντ, σεντς) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 και |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 και |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 και |$3$(\2:sp) == cardinal-neuter == (\d+) $1 == cardinal-feminine == 1 μια 3 τρεις 4 τέσσερις (\d) $1 1([34]) $(10)$(cardinal-feminine \2) (\d)([34]) $(\10) $(cardinal-feminine \2) (\d\d) $1 1(\d\d) $(100)[ $(cardinal-feminine \1)] 2(\d\d) διακόσιες[ $(cardinal-feminine \1)] 3(\d\d) τριακόσιες[ $(cardinal-feminine \1)] 4(\d\d) τετρακόσιες[ $(cardinal-feminine \1)] 5(\d\d) πεντακόσιες[ $(cardinal-feminine \1)] 6(\d\d) εξακόσιες[ $(cardinal-feminine \1)] 7(\d\d) επτακόσιες[ $(cardinal-feminine \1)] 8(\d\d) οκτακόσιες[ $(cardinal-feminine \1)] 9(\d\d) εννιακόσιες[ $(cardinal-feminine \1)] 1(\d{3}) χίλιες[ $(cardinal-feminine \1)] (\d{1,3})(\d{3}) $(cardinal-feminine \1) χίλιάδες[ $(cardinal-feminine \2)] (\d+000)(\d{3}) $(\1000)[ $(cardinal-feminine \2)] (\d+)(\d{6}) $(\1000000)[ $(cardinal-feminine \2)] == cardinal-masculine == 1 ένας 3 τρεις 4 τέσσερα (\d) $1 1([34]) $(10)$(cardinal-masculine \2) (\d)([34]) $(\10) $(cardinal-masculine \2) (\d\d) $1 1(\d\d) εκατό[ν $(cardinal-masculine \1)] 2(\d\d) διακόσιοι[ $(cardinal-masculine \1)] 3(\d\d) τριακόσιοι[ $(cardinal-masculine \1)] 4(\d\d) τετρακόσιοι[ $(cardinal-masculine \1)] 5(\d\d) πεντακόσιοι[ $(cardinal-masculine \1)] 6(\d\d) εξακόσιοι[ $(cardinal-masculine \1)] 7(\d\d) επτακόσιοι[ $(cardinal-masculine \1)] 8(\d\d) οκτακόσιοι[ $(cardinal-masculine \1)] 9(\d\d) εννιακόσιοι[ $(cardinal-masculine \1)] 1(\d{3}) χίλιοι[ $(cardinal-masculine \1)] (\d{1,3})(\d{3}) $(cardinal-feminine \1000)[ $(cardinal-masculine \2)] (\d+000)(\d{3}) $(\1000)[ $(cardinal-masculine \2)] (\d+)(\d{6}) $(\1000000)[ $(cardinal-masculine \2)] == to-feminine == (.*)ος(.*) $(to-feminine \1η\2) (.*)ός(.*) $(to-feminine \1ή\2) (.*) \1 == to-neuter == (.*)ος(.*) $(to-neuter \1ο\2) (.*)ός(.*) $(to-neuter \1ό\2) (.*) \1 == ordinal(-masculine)? == ^0 μηδενικός 1 πρώτος 2 δεύτερος 3 τρίτος 4 τέταρτος 5 πέμπτος 6 έκτος 7 έβδομος 8 όγδοος 9 ένατος 10 δέκατος 11 ενδέκατος 12 δωδέκατος 1(\d) δέκατος $(ordinal \2) 2(\d) εικοστός[ $(ordinal \2)] 3(\d) τριακοστός[ $(ordinal \2)] 4(\d) τεσσαρακοστός[ $(ordinal \2)] 5(\d) πεντηκοστός[ $(ordinal \2)] 6(\d) εξηκοστός[ $(ordinal \2)] 7(\d) εβδομηκοστός[ $(ordinal \2)] 8(\d) ογδοηκοστός[ $(ordinal \2)] 9(\d) εννενηκοστός[ $(ordinal \2)] 1(\d\d) εκατοστός[ $(ordinal \2)] 2(\d\d) διακοσιοστός[ $(ordinal \2)] 3(\d\d) τριακοσιοστός[ $(ordinal \2)] 4(\d\d) τετρακοσιοστός[ $(ordinal \2)] 5(\d\d) πεντακοσιοστός[ $(ordinal \2)] 6(\d\d) εξακοσιοστός[ $(ordinal \2)] 7(\d\d) επτακοσιοστός[ $(ordinal \2)] 8(\d\d) οκτακοσιοστός[ $(ordinal \2)] 9(\d\d) εννεακοσιοστός[ $(ordinal \2)] 1(\d{3}) χιλιοστός[ $(ordinal \2)] 2(\d{3}) δισχιλιοστός[ $(ordinal \2)] 3(\d{3}) τρισχιλιοστός[ $(ordinal \2)] 4(\d{3}) τετράκις χιλιοστός[ $(ordinal \2)] 5(\d{3}) πεντάκις χιλιοστός[ $(ordinal \2)] 6(\d{3}) εξάκις χιλιοστός[ $(ordinal \2)] 7(\d{3}) επτάκις χιλιοστός[ $(ordinal \2)] 8(\d{3}) οκτάκις χιλιοστός[ $(ordinal \2)] 9(\d{3}) εννεάκις χιλιοστός[ $(ordinal \2)] (\d)?10(\d{3}) [$(\200) ]δεκάκις χιλιοστός[ $(ordinal \3)] (\d{1,3})(\d{3}) $2 χιλιοστός[ $(ordinal \3)] (\d{1,3})(\d{6}) $2 εκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{9}) $2 δισεκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{12}) $2 τρισεκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{15}) $2 τετράκις εκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{18}) $2 πεντάκις εκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{21}) $2 εξάκις εκατομμυριοστός[ $(ordinal \3)] (\d{1,3})(\d{24}) $2 επτάκις εκατομμυριοστός[ $(ordinal \3)] == ordinal-feminine == (\d+) $(to-feminine $(ordinal \1)) == ordinal-neuter == (\d+) $(to-neuter $(ordinal \1)) == ordinal-number(-masculine)? == (\d*10) \2ος (\d*0) \2ός (\d+) \2ος == ordinal-number-feminine == (\d+) $(to-feminine $(ordinal-number \1)) == ordinal-number-neuter == (\d+) $(to-neuter $(ordinal-number \1)) == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-neuter)$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal)$(help ordinal-neuter)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number)$(help ordinal-number-neuter)$(help ordinal-number-feminine)$(help ordinal-number-masculine) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 zero 1 one 2 two 3 three 4 four 5 five 6 six 7 seven 8 eight 9 nine 10 ten 11 eleven 12 twelve 13 thirteen 15 fifteen 18 eighteen 1(\d) $1teen 2(\d) twenty[-$1] 3(\d) thirty[-$1] 4(\d) forty[-$1] 5(\d) fifty[-$1] 8(\d) eighty[-$1] (\d)(\d) $1ty[-$2] # separator function :0+ # one million :0*\d?\d " and " # one million and twenty-two :\d+ ", " # one million, one thousand (\d)(\d\d) $1 hundred[ and $2] # one hundred and one [:en-AU:] [:en-GB:] [:en-IE:] [:en-NZ:] (\d)(\d\d) $1 hundred[ $2] # default: one hundred one (\d{1,2})([1-9]\d\d) $1 thousand[ $2] # ten thousand two hundred (\d{1,2})(\d{3}) $1 thousand$(:\2)$2 # [:en-IN:] one hundred thousand, two hundred (\d{1,2})(000\d\d) $1 lakh$(:\2)$2 # [:en-IN:] one lakh and two (\d{1,2})(\d{5}) $1 lakh[ $2] # [:en-IN:] one lakh two hundred (\d{1,4})(\d{7}) $1 crore$(:\2)$2 # [:en-IN:] (\d{1,3})(\d{3}) $1 thousand$(:\2)$2 # one hundred thousand, two hundred (\d{1,3})(\d{6}) $1 million$(:\2)$2 (\d{1,3})(\d{9}) $1 billion$(:\2)$2 (\d{1,3})(\d{12}) $1 trillion$(:\2)$2 (\d{1,3})(\d{15}) $1 quadrillion$(:\2)$2 (\d{1,3})(\d{18}) $1 quintillion$(:\2)$2 (\d{1,3})(\d{21}) $1 sextillion$(:\2)$2 (\d{1,3})(\d{24}) $1 septillion$(:\2)$2 (\d{1,3})(\d{27}) $1 octillion$(:\2)$2 (\d{1,3})(\d{30}) $1 nonillion$(:\2)$2 (\d{1,3})(\d{33}) $1 decillion$(:\2)$2 (\d{1,3})(\d{36}) $1 undecillion$(:\2)$2 (\d{1,3})(\d{39}) $1 duodecillion$(:\2)$2 (\d{1,3})(\d{42}) $1 tredecillion$(:\2)$2 # negative number [-−](\d+) negative |$1 # decimals 0[.,] point ([-−]?\d+)[.,] $1| point ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 AUD:(\D+) $(\1: Australian dollar, Australian dollars, cent, cents) BGN:(\D+) $(\1: lev, leva, stotinka, stotinki) BWP:(\D+) $(\1: pula, pula, thebe, thebe) BZD:(\D+) $(\1: Belize dollar, Belize dollars, cent, cents) CAD:(\D+) $(\1: Canadian dollar, Canadian dollars, cent, cents) CHF:(\D+) $(\1: Swiss franc, Swiss francs, centime, centimes) CNY:(\D+) $(\1: Chinese yuan, Chinese yuan, fen, fen) CZK:(\D+) $(\1: Czech koruna, Czech koruny, halér, halére) DKK:(\D+) $(\1: Danish krone, Danish kroner, øre, øre) EEK:(\D+) $(\1: kroon, kroonid, sent, senti) EUR:(\D+) $(\1: euro, euro, cent, cents) GBP:(\D+) $(\1: pound sterling, pounds sterling, penny, pence) GHS:(\D+) $(\1: Ghana cedi, Ghana cedis, pesewa, pesewas) GMD:(\D+) $(\1: dalasi, dalasi, butut, bututs) HKD:(\D+) $(\1: Hong Kong dollar, Hong Kong dollars, cent, cents) HRK:(\D+) $(\1: kuna, kuna, lipa, lipa) HUF:(\D+) $(\1: forint, forint, fillér, fillér) ILS:(\D+) $(\1: Israeli shekel, Israeli shekels, agora, agoras) INR:(\D+) $(\1: Indian rupee, Indian rupees, paisa, paise) JMD:(\D+) $(\1: Jamaica dollar, Jamaica dollars, cent, cents) JPY:(\D+) $(\1: Japanese yen, Japanese yen, sen, sen) KES:(\D+) $(\1: Kenyan shilling, Kenyan shillings, cent, cents) KRW:(\D+) $(\1: Korean won, Korean won, jeon, jeon) LKR:(\D+) $(\1: Sri Lankan rupee, Sri Lankan rupees, cent, cents) LRD:(\D+) $(\1: Liberian dollar, Liberian dollars, cent, cents) LSL:(\D+) $(\1: loti, maloti, sente, lisente) LTL:(\D+) $(\1: litas, litai, centas, centai) LVL:(\D+) $(\1: lats, lati, santims, santimi) MGA:(\D+) $(\1: ariary, ariaries, iraimbilanja, iraimbilanja) MUR:(\D+) $(\1: Mauritian rupee, Mauritian rupees, cent, cents) MXN:(\D+) $(\1: Mexican peso, Mexican pesos, centavo, centavos) MWK:(\D+) $(\1: Malawian kwacha, Malawian kwacha, tambala, tambala) MYR:(\D+) $(\1: Ringgit, Ringgit, cent, cents) NAD:(\D+) $(\1: Namibian dollar, Namibian dollars, cent, cents) NGN:(\D+) $(\1: naira, naira, kobo, kobo) NZD:(\D+) $(\1: New Zealand dollar, New Zealand dollars, cent, cents) PGK:(\D+) $(\1: kina, kina, toea, toea) PHP:(\D+) $(\1: Philippine peso, Philippine pesos, centavo, centavos) PKR:(\D+) $(\1: Pakistani rupee, Pakistani rupees, paisa, paise) PLN:(\D+) $(\1: zloty, zlotys, grosz, groszy) RON:(\D+) $(\1: Romanian leu, Romanian lei, ban, bani) RSD:(\D+) $(\1: Serbian dinar, Serbian dinars, para, para) RUB:(\D+) $(\1: Russian ruble, Russian rubles, kopek, kopeks) RWF:(\D+) $(\1: Rwandese franc, Rwandese francs, centime, centimes) SDG:(\D+) $(\1: Sudanese pound, Sudanese pounds, piastre, piastres) SGD:(\D+) $(\1: Singapore dollar, Singapore dollars, cent, cents) SLL:(\D+) $(\1: leone, leones, cent, cents) SZL:(\D+) $(\1: lilangeni, emalangeni, cent, cents) THB:(\D+) $(\1: baht, baht, satang, satang) TRY:(\D+) $(\1: Turkish lira, Turkish lira, kurus, kurus) TTD:(\D+) $(\1: Trinidad and Tobago dollar, Trinidad and Tobago dollars, cent, cents) TZS:(\D+) $(\1: Tanzanian shilling, Tanzanian shillings, cent, cents) UAH:(\D+) $(\1: hryvnia, hryvnia, kopiyka, kopiyka) UGX:(\D+) $(\1: Uganda shilling, Uganda shillings, cent, cents) USD:(\D+) $(\1: U.S. dollar, U.S. dollars, cent, cents) X[AO]F:(\D+) $(\1: CFA franc, CFA francs, centime, centimes) ZAR:(\D+) $(\1: South African rand, South African rand, cent, cents) ZMW:(\D+) $(\1: Zambian kwacha, Zambian kwacha, ngwee, ngwee) ZW[DL]:(\D+) $(\1: Zimbabwe dollar, Zimbabwe dollars, cent, cents) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "((MGA|MRO) [-−]?\d+)[.,]0" $1 "((MGA|MRO) [-−]?\d+)[.,]2" $1 and |$(1)$(\2:ss) "((MGA|MRO) [-−]?\d+)[.,]4" $1 and |$(2)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]6" $1 and |$(3)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]8" $1 and |$(4)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 and |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 and |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 and |$3$(\2:sp) == money == "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(MGA|MRO) ([-−]?\d+)[.,]0" $2$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]2" $2 and 1/5$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]4" $2 and 2/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]6" $2 and 3/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]8" $2 and 4/5$(\1:up) "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) ([-−]?\d+))[.,](01)" $3 and 1/100$(\2:us) "(([A-Z]{3}) ([-−]?\d+))[.,](\d)" $3 and \40/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d)" $3 and \4/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d\d)" $3 and \4/1000$(\2:up) == ordinal == # convert to text, and recall to convert # cardinal names to ordinal ones ([-−]?\d+) $(ordinal |$1) (.*)one \1first (.*)two \1second (.*)three \1third (.*)five \1fifth (.*)eight \1eighth (.*)nine \1ninth (.*)twelve \1twelfth (.*)y \1ieth (.*) \1th == ordinal-number == (.*1\d) \1th (.*1) \1st (.*2) \1nd (.*3) \1rd (.*) \1th == year == (1[1-9])00 $1 hundred (1[1-9])([0-9][0-9]) $1 $2 (.*) $(year-remove-and $1) == year-remove-and == "(.*) and (.*)" \1 \2 (.*) \1 == help == "" $(1)|, $(2), $(3)\n$(\0 ordinal)$(\0 ordinal-number)year: $(year 1999), two thousand, $(year 2001)\ncurrency \(for example, USD\): $(USD 2.5)\nmoney USD: $(money USD 2.5) "(ordinal(-number)?|USD)" \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 nulo 1 unu 2 du 3 tri 4 kvar 5 kvin 6 ses 7 sep 8 ok 9 naŭ 1(\d) dek[ $1] (\d)(\d) $1dek[ $2] 1(\d\d) cent[ $1] (\d)(\d\d) $1cent[ $2] 1(\d{3}) mil[ $1] (\d{1,3})(\d{3}) $1 mil[ $2] 1(\d{6}) unu miliono[ $1] (\d{1,3})(\d{6}) $1 milionoj[ $2] 1(\d{9}) unu miliardo[ $1] (\d{1,3})(\d{9}) $1 miliardoj[ $2] 1(\d{12}) unu duiliono[ $1] (\d{1,3})(\d{12}) $1 duilionoj[ $2] 1(\d{15}) unu duiliardo[ $1] (\d{1,3})(\d{15}) $1 duiliardoj[ $2] 1(\d{18}) unu triiliono[ $1] (\d{1,3})(\d{18}) $1 triilionoj[ $2] 1(\d{21}) unu triiliardo[ $1] (\d{1,3})(\d{21}) $1 triiliardoj[ $2] # negative number [-−](\d+) negativa |$1 # decimals "([-−]?\d+)[.,]" "$1| komo" "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: svisa franko, svisaj frankoj, centimo, centimoj) CNY:(\D+) $(\1: ĉina juano, ĉinaj juanoj, fen-o, fen-oj) EUR:(\D+) $(\1: eŭro, eŭroj, cendo, cendoj) GBP:(\D+) $(\1: sterlinga pundo, sterlingaj pundoj, penco, pencoj) JPY:(\D+) $(\1: japana eno, japanaj enoj, seno, senoj) USD:(\D+) $(\1: usona dolaro, usonaj dolaroj, cendo, cendoj) "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sp) == ordinal == ([-−]?\d+) $1a == ordinal-number == (\d+) \1-a == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 cero 1$ uno 1 un 2 dos 3 tres 4 cuatro 5 cinco 6 seis 7 siete 8 ocho 9 nueve 10 diez 11 once 12 doce 13 trece 14 catorce 15 quince 16 dieciséis 1(\d) dieci$1 20 veinte 21$ veintiuno 21 veintiún 22 veintidós 23 veintitrés 26 veintiséis 2(\d) veinti$1 30 treinta 40 cuarenta 50 cincuenta 60 sesenta 70 setenta 80 ochenta 90 noventa (\d)(\d) $(\10) y $2 1(\d\d) cien[to $1] 500 quinientos 700 setecientos 900 novecientos ([579])(\d\d) $(\100) $2 (\d)(\d\d) $1cientos[ $2] 1(\d{3}) mil[ $1] (\d{1,3})(\d{3}) $1 mil[ $2] 1(\d{6}) un millón[ $1] (\d{1,6})(\d{6}) $1 millones[ $2] 1(\d{12}) un billón[ $1] (\d{1,6})(\d{12}) $1 billones[ $2] 1(\d{18}) un trillón[ $1] (\d{1,6})(\d{18}) $1 trillones[ $2] 1(\d{24}) un cuatrillón[ $1] (\d{1,6})(\d{24}) $1 cuatrillones[ $2] 1(\d{30}) un quintillón[ $1] (\d{1,6})(\d{30}) $1 quintillones[ $2] # negative number [-−](\d+) menos |$1 # decimals ([-−]?\d+)[.] $1| punto ([-−]?\d+)[,] $1| coma ([-−]?\d+[.,])([^0]\d) $1| |$2 ([-−]?\d+[.,])(\d)(\d)(\d) |$1 |$2| |$3| |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 ARS:(\D+) $(\1: peso argentino, pesos argentinos, centavo, centavos) BOB:(\D+) $(\1: boliviano, bolivianos, centavo, centavos) BZD:(\D+) $(\1: dólar beliceño, dólares beliceños, centavo, centavos) CEC:(\D+) $(\1: peso convertible, pesos convertibles, centavo, centavos) CHF:(\D+) $(\1: franco suizo, francos suizos, céntimo, céntimos) CLP:(\D+) $(\1: peso chileno, pesos chilenos, centavo, centavos) CNY:(\D+) $(\1: yuan renminbi, yuan renminbi, fen, fen) COP:(\D+) $(\1: peso colombiano, pesos colombianos, centavo, centavos) CRC:(\D+) $(\1: colón costarricense, colones costarricenses, céntimo, céntimos) DOP:(\D+) $(\1: peso dominicano, pesos dominicanos, centavo, centavos) ESP:(\D+) $(\1: peseta, pesetas, céntimo, céntimos) EUR:(\D+) $(\1: euro, euros, céntimo, céntimos) GBP:(\D+) $(\1: libra esterlina, libras esterlinas, penique, peniques) GTQ:(\D+) $(\1: quetzal, quetzales, centavo, centavos) HNL:(\D+) $(\1: lempira, lempiras, centavo, centavos) JPY:(\D+) $(\1: yen, yenes, sen, sen) MXN:(\D+) $(\1: peso mexicano, pesos mexicanos, centavo, centavos) NIO:(\D+) $(\1: córdoba, córdobas, centavo, centavos) PAB:(\D+) $(\1: balboa, balboas, céntimo, céntimos) PEN:(\D+) $(\1: sol, soles, centavo, centavos) PYG:(\D+) $(\1: guaraní, guaraníes, céntimo, céntimos) SVC:(\D+) $(\1: colón salvadoreño, colones salvadoreños, céntimo, céntimos) USD:(\D+) $(\1: dólar estadounidense, dólares estadounidenses, centavo, centavos) UYU:(\D+) $(\1: peso uruguayo, pesos uruguayos, centésimo, centésimos) VE[DS]:(\D+) $(\1: bolívar venezolano, bolívares venezolanos, centavo, centavos) VEF:(\D+) $(\1: bolívar fuerte, bolívares fuertes, céntimo, céntimos) # masculine to feminine conversion of "un" after millions, # if "as?$" matches currency name f:(.*ill)(.*),(.*) \1$(f:\2,\3) # don't modify un in millions f:(.*)[uú]n([^a].*,|,)(.*as?) $(f:\1una\2\3) # un libra -> una libra f:(.*ient)o(s.*),(.*as?) $(f:\1a\2,\3) # doscientos libra/libras -> doscientas f:(.*),(.*) \1\2 "([A-Z]{3}) ([-−]?1)([.,]00?)?"$(f:|$2,$(\1:us)) "([A-Z]{3}) ([-−]?\d+0{6,})([.,]00?)?" $2 de$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(f:|$2,$(\1:up)) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 con |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 con |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 con |$3$(\2:sp) # ordinal feminine:(.*ill)(.*) \1$(feminine:\2) # don't modify un in millions feminine:(.*ient)o(s.*) $(feminine:\1a\2) # doscientos -> doscientas feminine:(.*)[uú]no?([^a].*|$) $(feminine:\1una\2) # un -> una feminine:(.*) \1 == feminine == (.*) $(feminine:|$1|) == masculine == 1 un (.*) $1 == ordinal-masculine == (.*) $(ordinal \1) == ordinal == 1 primero 2 segundo 3 tercero 4 cuarto 5 quinto 6 sexto 7 séptimo 8 octavo 9 noveno 10 décimo 1([1-79]) decimo$(ordinal \1) 18 decimoctavo 20 vigésimo 2(\d) vigesimo$(ordinal \1) 30 trigésimo 40 cuadragésimo 50 quincuagésimo 60 sexagésimo 70 septuagésimo 80 octogésimo 90 nonagésimo (\d)(\d) $(ordinal \10) $(ordinal \2) 100 centésimo 200 ducentésimo 300 tricentésimo 400 cuadringentésimo 500 quingentésimo 600 sexcentésimo 700 septingentésimo 800 octingentésimo 900 noningentésimo (\d)(\d\d) $(ordinal \100) $(ordinal \2) 1(\d{3}) milésimo[ $(ordinal \1)] (\d{1,3})(\d{3}) $1 milésimo[ $(ordinal \2)] 1(\d{6}) millonésimo[ $(ordinal \1)] (\d{1,3})(\d{6}) $1 millonésimo[ $(ordinal \2)] 1(\d{9}) milmillonésimo[ $(ordinal \1)] (\d{1,3})(\d{9}) $1 milmillonésimo[ $(ordinal \2)] == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal-masculine \1)) (.*)o\b(.*) $(ordinal-feminine \1a\2) (.*) \1 == ordinal-masculine-adjective == ([-−]?\d+) $(ordinal-masculine-adjective $(ordinal-masculine \1)) (.*)decimoprimero \1undécimo (.*)decimosegundo \1duodécimo (.*(primer|tercer))o \1 (.*) \1 # ordinal abbreviation == (ordinal)-number(-feminine|-masculine|-masculine-adjective)? == ([-−]?\d+) \3$(ordinal-number $(\1\2 \3)) .*er .ᵉʳ .*a .ª .*o .º == help == "" $(1)|, $(2), $(3)\n$(\0 feminine)$(\0 masculine)$(\0 ordinal-number-masculine)$(\0 ordinal-number-masculine-adjective)$(\0 ordinal-number-feminine)$(\0 ordinal-feminine)$(\0 ordinal-masculine)$(\0 ordinal-masculine-adjective) (feminine|masculine|ordinal(-number)?(-feminine|-masculine)?(-adjective)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 null 1 üks 2 kaks 3 kolm 4 neli 5 viis 6 kuus 7 seitse 8 kaheksa 9 üheksa 10 kümme 1(\d) $1teist (\d)(\d) $1kümmend[ $2] 1(\d\d) sada[ $1] (\d)(\d\d) $1sada[ $2] 1(\d{3}) tuhat[ $1] (\d{1,3})(\d{3}) $1 tuhat[ $2] 1(\d{6}) miljon[ $1] (\d{1,3})(\d{6}) $1 miljonit[ $2] 1(\d{9}) miljard[ $1] (\d{1,3})(\d{9}) $1 miljardit[ $2] 1(\d{12}) biljon[ $1] (\d{1,3})(\d{12}) $1 biljonit[ $2] 1(\d{15}) biljard[ $1] (\d{1,3})(\d{15}) $1 biljardit[ $2] 1(\d{18}) triljon[ $1] (\d{1,3})(\d{18}) $1 triljonit[ $2] 1(\d{21}) triljard[ $1] (\d{1,3})(\d{21}) $1 triljardit[ $2] 1(\d{24}) kvadriljon[ $1] (\d{1,3})(\d{24}) $1 kvadriljonit[ $2] # negative numbers [-−](\d+) miinus |$1 # decimals ([-−]?\d+)[.,]([01]) |$1| ja |$2 kümnendikku ([-−]?\d+)[.,](\d) |$1| ja |$2 kümnendikku ([-−]?\d+)[.,]0([01]) |$1| ja |$2 sajandikku ([-−]?\d+)[.,](\d\d) |$1| ja |$2 sajandikku ([-−]?\d+)[.,]00([01]) |$1| ja |$2 tuhandikku ([-−]?\d+)[.,](\d\d\d) |$1| ja |$2 tuhandikku "([-−]?\d+)[.,](\d)(\d)(\d)(\d)" |$1| ja |$2| |$3| |$4| |$5| "([-−]?\d+[.,]\d+)(\d)" $1 |$2| # currency # unit/subunit singular/singular partitive us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: Šveitsi frank, Šveitsi franki, rapp, rappi) CNY:(\D+) $(\1: Hiina jüaan, Hiina jüaan, sent, senti) EEK:(\D+) $(\1: Eesti kroon, Eesti krooni, sent, senti) EUR:(\D+) $(\1: euro, eurot, sent, senti) GBP:(\D+) $(\1: Suurbritannia nael, Suurbritannia naela, penn, penni) JPY:(\D+) $(\1: Jaapani jeen, Jaapani jeeni, seniks, seniks) USD:(\D+) $(\1: USA dollar, USA dollarit, sent, senti) RUB:(\D+) $(\1: Vene rubla, Vene rublat, kopikas, kopikat) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)1" $1 $2 riniks "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 riniks "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,]10?" $1 $2 tsjao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 tsjaoga "(CNY [-−]?\d+[.,]\d)1" $1 $2 fõn "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fõniga "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 ja $(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 ja $(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 ja $3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d\d)" $1 ja $3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d\d\d)" $1 ja $3$(\2:sp) == ordinal == ^0 null 1 esimene 2 teine 3 kolmas ([4-9])$ $(ordinal \1)s 4 nelja 5 viie 6 kuue 7 seitsme 8 kaheksa 9 üheksa 10 kümnes 11 üheteistkümnes 12 kaheteistkümnes 13 kolmeteistkümnes 1(\d) $(ordinal \1)teistkümnes 20 kahekümnes 2(\d) kahekümne[ $(ordinal \1)] 30 kolmekümnes 3(\d) kolmekümne[ $(ordinal \1)] (\d)0 $(ordinal \1)kümnes (\d)(\d) $(ordinal \1)kümne $(ordinal \2) 100 sajas 1(\d\d) saja[ $(ordinal \1)] 200 kahesajas 2(\d\d) kahesaja[ $(ordinal \1)] (\d)(\d\d) $(ordinal \1)saja[ $(ordinal \2)] 1(\d{3}) tuhandes[ $(ordinal \1)] (\d{1,3})(\d{3}) $(ordinal \1)tuhande[ $(ordinal \2)] 1(\d{6}) miljones[ $(ordinal \1)] (\d{1,3})(\d{6}) $(ordinal \1)miljone[ $(ordinal \2)] 1(\d{9}) miljardes[ $(ordinal \1)] (\d{1,3})(\d{9}) $(ordinal \1)miljarde[ $(ordinal \2)] 1(\d{12}) biljones[ $(ordinal \1)] (\d{1,3})(\d{12}) $(ordinal \1)biljone[ $(ordinal \2)] == ordinal-number == (\d+) \1. == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1)|, $(\1 2)|, $(\1 3)\n
^0 صفر 1 یک 2 دو 3 سه 4 چهار 5 پنج 6 شش 7 هفت 8 هشت 9 نه 10 ده 11 یازده 12 دوازده 13 سیزده 14 چهارده 15 پانزده 16 شانزده 17 هفده 18 هجده 19 نوزده 2(\d) بیست[ و $1] 3(\d) سی[ و $1] 4(\d) چهل[ و $1] 5(\d) پنجاه[ و $1] 6(\d) شصت[ و $1] 7(\d) هفتاد[ و $1] 8(\d) هشتاد[ و $1] 9(\d) نود[ و $1] # separator function :0+ # one million :0*\d?\d " و " # one million and twenty-two :\d+ " و " # one million, one thousand 2(\d\d) دویست[ و $1] 3(\d\d) سیصد[ و $1] 5(\d\d) پانصد[ و $1] (\d)(\d\d) $1صد[ و $2] (\d{1,2})([1-9]\d\d) $1 هزار و[ $2] (\d{1,3})(\d{3}) $1 هزار$(:\2)$2 (\d{1,3})(\d{6}) $1 میلیون$(:\2)$2 (\d{1,3})(\d{9}) $1 میلیارد$(:\2)$2 (\d{1,3})(\d{12}) $1 تریلیون$(:\2)$2 (\d{1,3})(\d{15}) $1 کوادریلیون$(:\2)$2 (\d{1,3})(\d{18}) $1 کوینتیلیون$(:\2)$2 (\d{1,3})(\d{21}) $1 سکستیلیون$(:\2)$2 (\d{1,3})(\d{24}) $1 سپتیلیون$(:\2)$2 (\d{1,3})(\d{27}) $1 اکتیلیون$(:\2)$2 (\d{1,3})(\d{30}) $1 نانیلیون$(:\2)$2 (\d{1,3})(\d{33}) $1 دسیلیون$(:\2)$2 (\d{1,3})(\d{36}) $1 آندسیلیون$(:\2)$2 (\d{1,3})(\d{39}) $1 دیودسیلیون$(:\2)$2 (\d{1,3})(\d{42}) $1 تریدسیلیون$(:\2)$2 (\d{1,3})(\d{45}) $1 کواتیوردسیلیون$(:\2)$2 (\d{1,3})(\d{48}) $1 کویندسیلیون$(:\2)$2 (\d{1,3})(\d{51}) $1 سکسدسیلیون$(:\2)$2 (\d{1,3})(\d{54}) $1 سپتدسیلیون$(:\2)$2 (\d{1,3})(\d{57}) $1 اُکتودسیلیون$(:\2)$2 (\d{1,3})(\d{60}) $1 نومدسیلیون$(:\2)$2 (\d{1,3})(\d{63}) $1 ویجینتیلیون$(:\2)$2 (\d{1,3})(\d{66}) $1 آنویجینتیلیون$(:\2)$2 (\d{1,3})(\d{69}) $1 دویجینتیلیون$(:\2)$2 (\d{1,3})(\d{72}) $1 ترسویجینتیلیون$(:\2)$2 (\d{1,3})(\d{75}) $1 کوادرویجینتیلیون$(:\2)$2 (\d{1,3})(\d{78}) $1 کوینکاویجینتیلیون$(:\2)$2 (\d{1,3})(\d{81}) $1 سیسویجینتیلیون$(:\2)$2 (\d{1,3})(\d{84}) $1 سپتمویجینتیلیون$(:\2)$2 (\d{1,3})(\d{87}) $1 آکتوویجینتیلیون$(:\2)$2 (\d{1,3})(\d{90}) $1 نومویجینتیلیون$(:\2)$2 (\d{1,3})(\d{93}) $1 تریویجینتیلیون$(:\2)$2 (\d{1,3})(\d{96}) $1 آنتریویجینتیلیون$(:\2)$2 (\d{1,3})(\d{99}) $1 دوتریویجینتیلیون$(:\2)$2 (\d{1,3})(\d{100}) $1 گوگول$(:\2)$2 # negative number [-−](\d+) منفی |$1 # decimals 0[.,] ممیز ([-−]?\d+)[.,] $1| ممیز ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 ZMW:(\D+) $(\1: کواچای زامبیا, کواچای زامبیا, نگوی, نگوی) ZAR:(\D+) $(\1: رند آفریقای جنوبی, رند آفریقای جنوبی, سنت, سنت) YER:(\D+) $(\1: ریال یمن, ریال یمن, فلس, فلس) WST:(\D+) $(\1: طلای ساموآ, طلای ساموآ, سن, سن) VUV:(\D+) $(\1: واتوی وانواتو, واتوی وانواتو,,) VND:(\D+) $(\1: دانگ ویتنام, دانگ ویتنام, هائو, هائو) VES:(\D+) $(\1: بولیوار ونزوئلا, بولیوار ونزوئلا, سنتیمو, سنتیمو) UZS:(\D+) $(\1: سوم ازبکستان, سوم ازبکستان, تین, تین) UYU:(\D+) $(\1: پزوی اروگوئه, پزوی اروگوئه, سنتسیمو, سنتسیمو) USD:(\D+) $(\1: دلار آمریکا, دلار آمریکا, سنت, سنت) UGX:(\D+) $(\1: شیلینگ اوگاندا, شیلینگ اوگاندا,,) UAH:(\D+) $(\1: گریونا اوکراین, گریونا اوکراین, کوپک, کوپک) TZS:(\D+) $(\1: شیلینگ تانزانیا, شیلینگ تانزانیا, سنت, سنت) TWD:(\D+) $(\1: دلار جدید تایوان, دلار جدید تایوان, سنت, سنت) TTD:(\D+) $(\1: دلار ترینیداد و توباگو, دلار ترینیداد و توباگو, سنت, سنت) TRY:(\D+) $(\1: لیره ترک, لیره ترک, قرش, قرش) TOP:(\D+) $(\1: پاآنگای تونگا, پاآنگای تونگا, سنیتی, سنیتی) TND:(\D+) $(\1: دینار تونس, دینار تونس, میلیم, میلیم) TMT:(\D+) $(\1: منات ترکمنستان, منات ترکمنستان, تنگه, تنگه) TJS:(\D+) $(\1: سامانی تاجیکستان, سامانی تاجیکستان, درم, درم) THB:(\D+) $(\1: بات تایلند, بات تایلند, ساتانگ, ساتانگ) SYP:(\D+) $(\1: لیره سوریه, لیره سوریه, قرش, قرش) SSP:(\D+) $(\1: پوند سودان جنوبی, پوند سودان جنوبی, قرش, قرش) SRD:(\D+) $(\1: دلار سورینام, دلار سورینام, سنت, سنت) SOS:(\D+) $(\1: شیلینگ سومالی, شیلینگ سومالی, سنت, سنت) SLS:(\D+) $(\1: شیلینگ سومالیلند, شیلینگ سومالیلند, سنت, سنت) SLL:(\D+) $(\1: لئون سیرالئون, لئون سیرالئون, سنت, سنت) SGD:(\D+) $(\1: دلار سنگاپور, دلار سنگاپور, سنت, سنت) SEK:(\D+) $(\1: کرون سوئد, کرون سوئد, اوره, اوره) SDG:(\D+) $(\1: پوند سودان, پوند سودان, قرش, قرش) SCR:(\D+) $(\1: روپیه سیشل, روپیه سیشل, سنت, سنت) SBD:(\D+) $(\1: دلار جزایر سلیمان, دلار جزایر سلیمان, سنت, سنت) RWF:(\D+) $(\1: فرانک رواندا, فرانک رواندا, سانتیم, سانتیم) RUB:(\D+) $(\1: روبل روسیه, روبل روسیه, کوپک, کوپک) RSD:(\D+) $(\1: دینار صربستان, دینار صربستان, پارا, پارا) RON:(\D+) $(\1: لئوی رومانی, لئوی رومانی, بان, بان) PYG:(\D+) $(\1: گوارانی پاراگوئه, گوارانی پاراگوئه, سنتیمو, سنتیمو) PRB:(\D+) $(\1: روبل ترانسنیسترین, روبل ترانسنیسترین, کوپک, کوپک) PLN:(\D+) $(\1: زلوتی لهستان, زلوتی لهستان, گروش, گروش) PKR:(\D+) $(\1: روپیه پاکستان, روپیه پاکستان, پیسه, پیسه) PHP:(\D+) $(\1: پزو فیلیپین, پزو فیلیپین, سنتیمو, سنتیمو) PGK:(\D+) $(\1: کینای پاپوآ گینه نو, کینای پاپوآ گینه نو, تویا, تویا) PEN:(\D+) $(\1: سول پرو, سول پرو, سنتیمو, سنتیمو) NZD:(\D+) $(\1: دلار نیوزیلند, دلار نیوزیلند, سنت, سنت) NOK:(\D+) $(\1: کرون نروژ, کرون نروژ, اوره, اوره) NIO:(\D+) $(\1: کوردوبای نیکاراگوئه, کوردوبای نیکاراگوئه, سنتاوو, سنتاوو) NGN:(\D+) $(\1: نایرا نیجریه, نایرا نیجریه, کوبو, کوبو) MZN:(\D+) $(\1: متیکال موزامبیک, متیکال موزامبیک, سنتاوو, سنتاوو) MYR:(\D+) $(\1: رینگیت مالزی, رینگیت مالزی, سن, سن) MXN:(\D+) $(\1: پزو مکزیک, پزو مکزیک, سنتاوو, سنتاوو) MWK:(\D+) $(\1: کواچا مالاویا, کواچا مالاویا, تامبالا, تامبالا) MUR:(\D+) $(\1: روپیه موریس, روپیه موریس, سنت, سنت) MRU:(\D+) $(\1: اوقیه موریتانی, اوقیه موریتانی, خمس, خمس) MNT:(\D+) $(\1: توگروگ مغولستان, توگروگ مغولستان, مونگو, مونگو) MMK:(\D+) $(\1: کیات میانمار, کیات میانمار, پیا, پیا) MKD:(\D+) $(\1: دینار مقدونیه, دینار مقدونیه, دنی, دنی) MGA:(\D+) $(\1: آریاری ماداگاسکار, آریاری ماداگاسکار, ایراایمبیلانجا, ایراایمبیلانجا) MDL:(\D+) $(\1: لئوی مولداوی, لئوی مولداوی, بان, بان) LYD:(\D+) $(\1: دینار لیبی, دینار لیبی, درهم, درهم) LRD:(\D+) $(\1: دلار لیبریا, دلار لیبریا, سنت, سنت) LKR:(\D+) $(\1: روپیه سریلانکا, روپیه سریلانکا, سنت, سنت) LAK:(\D+) $(\1: کیپ لائوس, کیپ لائوس, ات, ات) KZT:(\D+) $(\1: تنگه قزاقستان, تنگه قزاقستان, تیین, تیین) KRW:(\D+) $(\1: وون کره جنوبی, وون کره جنوبی, جیون, جیون) KPW:(\D+) $(\1: وون کره شمالی, وون کره شمالی, چون, چون) KHR:(\D+) $(\1: ریال کامبوج, ریال کامبوج, سن, سن) KGS:(\D+) $(\1: سوم قرقیزستان, سوم قرقیزستان, تیین, تیین) KES:(\D+) $(\1: شیلینگ کنیا, شیلینگ کنیا, سنت, سنت) JPY:(\D+) $(\1: ین ژاپن, ین ژاپن, سن, سن) JMD:(\D+) $(\1: دلار جامائیکا, دلار جامائیکا, سنت, سنت) ISK:(\D+) $(\1: کرونای ایسلند, کرونای ایسلند, اوره, اوره) IRR:(\D+) $(\1: ریال ایران, ریال ایران, دینار, دینار) IQD:(\D+) $(\1: دینار عراق, دینار عراق, فلس, فلس) INR:(\D+) $(\1: روپیه هند, روپیه هند, پیسه, پیسه) ILS:(\D+) $(\1: شکل جدید اسرائیل, شکل جدید اسرائیل, آگوروت, آگوروت) IDR:(\D+) $(\1: روپیه اندونزی, روپیه اندونزی, سن, سن) HUF:(\D+) $(\1: فورینت مجارستان, فورینت مجارستان, فیلر, فیلر) HTG:(\D+) $(\1: گورد هائیتی, گورد هائیتی, سانتیم, سانتیم) HRK:(\D+) $(\1: کونای کرواسی, کونای کرواسی, لیپا, لیپا) HNL:(\D+) $(\1: لامپیرای هندوراس, لامپیرای هندوراس, سنتاوو, سنتاوو) GYD:(\D+) $(\1: دلار گویان, دلار گویان, سنت, سنت) GTQ:(\D+) $(\1: کوتزال گواتمالا, کوتزال گواتمالا, سنتاوو, سنتاوو) GNF:(\D+) $(\1: فرانک گینه, فرانک گینه, سانتیم, سانتیم) GMD:(\D+) $(\1: دالاسی گامبیا, دالاسی گامبیا, بوتوت, بوتوت) GHS:(\D+) $(\1: سدی غنا, سدی غنا, پسوا, پسوا) GEL:(\D+) $(\1: لاری گرجستان, لاری گرجستان, تتری, تتری) GBP:(\D+) $(\1: پوند استرلینگ, پوند استرلینگ, پنی, پنی) FJD:(\D+) $(\1: دلار فیجی, دلار فیجی, سنت, سنت) EUR:(\D+) $(\1: یورو, یورو, سنت, سنت) ETB:(\D+) $(\1: بیر اتیوپی, بیر اتیوپی, سانتیم, سانتیم) EGP:(\D+) $(\1: پوند مصر, پوند مصر, قرش, قرش) DZD:(\D+) $(\1: دینار الجزایر, دینار الجزایر, سانتیم, سانتیم) DOP:(\D+) $(\1: پزو دومینیکن, پزو دومینیکن, سنتاوو, سنتاوو) CZK:(\D+) $(\1: کرونای چک, کرونای چک, هالر, هالر) CUP:(\D+) $(\1: پزوی کوبا, پزوی کوبا, سنتاوو, سنتاوو) CRC:(\D+) $(\1: کولون کاستاریکا, کولون کاستاریکا, سنتیمو, سنتیمو) COP:(\D+) $(\1: پزو کلمبیا, پزو کلمبیا, سنتاوو, سنتاوو) CNY:(\D+) $(\1: رنمینبی, رنمینبی, جیائو, جیائو) CLP:(\D+) $(\1: پزو شیلی, پزو شیلی, سنتاوو, سنتاوو) CHF:(\D+) $(\1: فرانک سوئیس, فرانک سوئیس, سانتیم, سانتیم) CDF:(\D+) $(\1: فرانک کنگو, فرانک کنگو, سانتیم, سانتیم) CAD:(\D+) $(\1: دلار کانادا, دلار کانادا, سنت, سنت) BYN:(\D+) $(\1: روبل بلاروس, روبل بلاروس, کاپیکا, کاپیکا) BWP:(\D+) $(\1: پولای بوتسوانا, پولای بوتسوانا, تیب, تیب) BRL:(\D+) $(\1: رئال برزیل, رئال برزیل, سنتاوو, سنتاوو) BOB:(\D+) $(\1: بولیویانو بولیوی, بولیویانو بولیوی, سنتاوو, سنتاوو) BIF:(\D+) $(\1: فرانک بوروندی, فرانک بوروندی, سانتیم, سانتیم) BDT:(\D+) $(\1: تاکا بنگلادش, تاکا بنگلادش, پیسه, پیسه) AZN:(\D+) $(\1: منات آذربایجان, منات آذربایجان, گپیک, گپیک) AUD:(\D+) $(\1: دلار استرالیا, دلار استرالیا, سنت, سنت) ARS:(\D+) $(\1: پزو آرژانتین, پزو آرژانتین, سنتاوو, سنتاوو) AOA:(\D+) $(\1: کوانزای آنگولا, کوانزای آنگولا, سنتیمو, سنتیمو) AMD:(\D+) $(\1: درام ارمنستان, درام ارمنستان, لوما, لوما) ALL:(\D+) $(\1: لک آلبانی, لک آلبانی, کیندارکا, کیندارکا) AFN:(\D+) $(\1: افغانی افغانستان, افغانی افغانستان, پول, پول) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "((MGA|MRO) [-−]?\d+)[.,]0" $1 "((MGA|MRO) [-−]?\d+)[.,]2" $1 و |$(1)$(\2:ss) "((MGA|MRO) [-−]?\d+)[.,]4" $1 و |$(2)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]6" $1 و |$(3)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]8" $1 و |$(4)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 و |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 و |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 و |$3$(\2:sp) == money == "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(MGA|MRO) ([-−]?\d+)[.,]0" $2$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]2" $2 و 1/5$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]4" $2 و 2/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]6" $2 و 3/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]8" $2 و 4/5$(\1:up) "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) ([-−]?\d+))[.,](01)" $3 و 1/100$(\2:us) "(([A-Z]{3}) ([-−]?\d+))[.,](\d)" $3 و \40/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d)" $3 و \4/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d\d)" $3 و \4/1000$(\2:up) == ordinal == # convert to text, and recall to convert # cardinal names to ordinal ones ([-−]?\d+) $(ordinal |$1) (.*)سه \1سومین (.*) \1مین == ordinal-number == (.*) \1مین == year == (.*) \1 == help == "" $(1)|, $(2), $(3)\n$(\0 ordinal)$(\0 ordinal-number)year: $(year 1999), two thousand, $(year 2001)\ncurrency \(for example, USD\): $(USD 2.5)\nmoney USD: $(money USD 2.5) "(ordinal(-number)?|USD)" \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 nolla 1 yksi 2 kaksi 3 kolme 4 neljä 5 viisi 6 kuusi 7 seitsemän 8 kahdeksan 9 yhdeksän 10 kymmenen 1(\d) $1toista (\d)(\d) $1kymmentä$2 1(\d\d) sata$1 (\d)(\d\d) $1sataa$2 1(\d{3}) tuhat$1 (\d)(\d{3}) $1tuhatta$2 (\d{2,3})(\d{3}) $1tuhatta[ $2] 1(\d{6}) miljoona[ $1] (\d{1,3})(\d{6}) $1 miljoonaa[ $2] 1(\d{9}) miljardi[ $1] (\d{1,3})(\d{9}) $1 miljardia[ $2] 1(\d{12}) biljoona[ $1] (\d{1,3})(\d{12}) $1 biljoonaa[ $2] 1(\d{15}) tuhat biljoonaa[ $1] (\d{1,3})(\d{15}) $1 tuhatta biljoonaa[ $2] 1(\d{18}) triljoona[ $1] (\d{1,3})(\d{18}) $1 triljoonaa[ $2] 1(\d{21}) tuhat triljoonaa[ $1] (\d{1,3})(\d{21}) $1 tuhatta triljoonaa[ $2] 1(\d{24}) kvadriljoona[ $1] (\d{1,3})(\d{24}) $1 kvadriljoonaa[ $2] # negative numbers [-−](\d+) miinus |$1 # decimals ([-−]?\d+)[.,]([01]) |$1| ja |$2 kymmenesosa ([-−]?\d+)[.,](\d) |$1| ja |$2 kymmenesosaa ([-−]?\d+)[.,]0([01]) |$1| ja |$2 sadasosa ([-−]?\d+)[.,](\d\d) |$1| ja |$2 sadasosaa ([-−]?\d+)[.,]00([01]) |$1| ja |$2 tuhannesosa ([-−]?\d+)[.,](\d\d\d) |$1| ja |$2 tuhannesosaa "([-−]?\d+)[.,](\d)(\d)(\d)(\d)" |$1| ja |$2| |$3| |$4| |$5| "([-−]?\d+[.,]\d+)(\d)" $1 |$2| # currency # unit/subunit singular/singular partitive us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 ALL:(\D+) $(\1: Albanian lek, Albanian lekiä, qindarkë, qindarkëa) AUD:(\D+) $(\1: Australian dollari, Australian dollaria, sentti, senttiä) AZN:(\D+) $(\1: Azerbaidžanin manat, Azerbaidžanin manatia, qepik, qepikia) BAM:(\D+) $(\1: Bosnia-Hertsegovinan vaihdettava markka, Bosnia-Hertsegovinan vaihdettavaa markkaa, fening, feningiä) BGN:(\D+) $(\1: Bulgarian lev, Bulgarian leviä, stotinka, stotinkaa) BYN:(\D+) $(\1: Valko-Venäjän rupla, Valko-Venäjän ruplaa, kopeekka, kopeekkaa) CAD:(\D+) $(\1: Kanadan dollari, Kanadan dollaria, sentti, senttiä) CHF:(\D+) $(\1: Sveitsin frangi, Sveitsin frangia, rappeni, rappenia) CNY:(\D+) $(\1: Kiinan juan, Kiinan juania, fen, feniä) CYP:(\D+) $(\1: Kyproksen punta, Kyproksen puntaa, sentti, senttiä) CZK:(\D+) $(\1: Tšekin koruna, Tšekin korunaa, haléř, haléřia) DKK:(\D+) $(\1: Tanskan kruunu, Tanskan kruunua, äyri, äyriä) EEK:(\D+) $(\1: Viron kruunu, Viron kruunua, sentti, senttiä) EUR:(\D+) $(\1: euro, euroa, sentti, senttiä) GBP:(\D+) $(\1: Englannin punta, Englannin puntaa, penny, pennyä) GEL:(\D+) $(\1: Georgian lari, Georgian laria, tetri, tetriä) GIP:(\D+) $(\1: Gibraltarin punta, Gibraltarin puntaa, penny, pennyä) HKD:(\D+) $(\1: Hongkongin dollari, Hongkongin dollaria, sentti, senttiä) HRK:(\D+) $(\1: Kroatian kuna, Kroatian kunaa, lipa, lipaa) HUF:(\D+) $(\1: Unkarin forintti, Unkarin forinttia, filléri, fillériä) IDR:(\D+) $(\1: Indonesian rupia, Indonesian rupiaa, sen, seniä) ISK:(\D+) $(\1: Islannin kruunu, Islannin kruunua, äyri, äyriä) JPY:(\D+) $(\1: Japanin jeni, Japanin jeniä, sen, seniä) KRW:(\D+) $(\1: Etelä-Korean won, Etelä-Korean wonia, chon, chonia) LTL:(\D+) $(\1: Liettuan liti, Liettuan litiä, centas, centasia) LVL:(\D+) $(\1: Latvian lati, Latvian latia, santiimi, santiimia) MDL:(\D+) $(\1: Moldovan leu, Moldovan leuta, ban, bania) MKD:(\D+) $(\1: Makedonian denaari, Makedonian denaaria, deni, deniä) MYR:(\D+) $(\1: Malesian ringgit, Malesian ringgitia, sen, seniä) NZD:(\D+) $(\1: Uuden-Seelannin dollari, Uuden-Seelannin dollaria, sentti, senttiä) NOK:(\D+) $(\1: Norjan kruunu, Norjan kruunua, äyri, äyriä) PHP:(\D+) $(\1: Filippiinien peso, Filippiinien pesoa, centavo, centavoa) PLN:(\D+) $(\1: Puolan zloty, Puolan zlotya, grosz, groszia) RON:(\D+) $(\1: Romanian leu, Romanian leuta, ban, bania) RSD:(\D+) $(\1: Serbian dinaari, Serbian dinaaria, para, paraa) RUB:(\D+) $(\1: Venäjän rupla, Venäjän ruplaa, kopeekka, kopeekkaa) SEK:(\D+) $(\1: Ruotsin kruunu, Ruotsin kruunua, äyri, äyriä) SGD:(\D+) $(\1: Singaporen dollari, Singaporen dollaria, sentti, senttiä) THB:(\D+) $(\1: Thaimaan baht, Thaimaan bahtia, satang, satangia) TRY:(\D+) $(\1: Turkin liira, Turkin liiraa, kuruş, kuruşia) UAH:(\D+) $(\1: Ukrainan hryvnia, Ukrainan hryvniaa, kopeekka, kopeekkaa) USD:(\D+) $(\1: Yhdysvaltain dollari, Yhdysvaltain dollaria, sentti, senttiä) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)1" $1 $2 rin "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 riniä "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) # chiao? "(CNY [-−]?\d+)[.,]10?" $1 $2 chiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 chiaota "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 feniä "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 $(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:sp) == ordinal == ^0 nollas 1$ ensimmäinen 2$ toinen 2 kahdes 3 kolmas 4 neljäs 5 viides 6 kuudes 7 seitsemäs 8 kahdeksas 9 yhdeksäs 10 kymmenes 11 yhdestoista 12 kahdestoista 1(\d) $(ordinal \1)toista (\d)(\d) $(ordinal \1)kymmenes$(ordinal \2) 1(\d\d) sadas$(ordinal \1) (\d)(\d\d) $(ordinal \1)sadas$(ordinal \2) 1(\d{3}) tuhannes$(ordinal \1) (\d)(\d{3}) $(ordinal \1)tuhannes$(ordinal \2) (\d{2,3})(\d{3}) $(ordinal \1)|tuhannes[ $(ordinal \2)] (\d)(\d{6}) $(ordinal \1)miljoonas[ $(ordinal \2)] (\d{2,3})(\d{6}) $(ordinal \1)| miljoonas[ $(ordinal \2)] (\d)(\d{6}) $(ordinal \1)miljoonas[ $(ordinal \2)] (\d{2,3})(\d{6}) $(ordinal \1)| miljoonas[ $(ordinal \2)] (\d)(\d{9}) $(ordinal \1)miljardis[ $(ordinal \2)] (\d{2,3})(\d{9}) $(ordinal \1)| miljardis[ $(ordinal \2)] (\d)(\d{12}) $(ordinal \1)biljoonas[ $(ordinal \2)] (\d{2,3})(\d{12}) $(ordinal \1)| biljoonas[ $(ordinal \2)] == ordinal-number == (\d+) \1. == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1)|, $(\1 2)|, $(\1 3)\n
^0 zéro 1 un 2 deux 3 trois 4 quatre 5 cinq 6 six 7 sept 8 huit 9 neuf 10 dix 11 onze 12 douze 13 treize 14 quatorze 15 quinze 16 seize 20 vingt 30 trente 40 quarante 50 cinquante 60 soixante 71 septante-et-un # [:fr-CH:] [:fr-BE:] 7(\d) septante[-$1] # [:fr-CH:] [:fr-BE:] 71 soixante-et-onze # default 7(\d) soixante-$(1\1) # default 81 huitante-et-un # [:fr-CH:] 8(\d) huitante[-$1] # [:fr-CH:] 80$ quatre-vingts # default 80 quatre-vingt # default 81 quatre-vingt-un # default 91 nonante-et-un # [:fr-CH:] [:fr-BE:] 9(\d) nonante[-$1] # [:fr-CH:] [:fr-BE:] 9(\d) quatre-vingt-$(1\1) # default (\d)1 $(\10)-et-un (\d)(\d) $(\10)-$2 1(\d\d) cent[-$1] (\d)00$ $1-cents (\d)(\d\d) $1-cent[-$2] 1(\d{3}) mille[-$1] (\d{1,3})(\d{3}) $1-mille[-$2] 1(\d{6}) un-million[-$1] (\d{1,3})(\d{6}) $1|-millions[-$2] 1(\d{9}) un-milliard[-$1] (\d{1,3})(\d{9}) $1|-milliards[-$2] 1(\d{12}) un-billion[-$1] (\d{1,3})(\d{12}) $1|-billions[-$2] 1(\d{15}) un-billiard[-$1] (\d{1,3})(\d{15}) $1|-billiards[-$2] 1(\d{18}) un-trillion[-$1] (\d{1,3})(\d{18}) $1|-trillions[-$2] 1(\d{21}) un-trilliard[-$1] (\d{1,3})(\d{21}) $1|-trilliards[-$2] 1(\d{24}) un-quadrillion[-$1] (\d{1,3})(\d{24}) $1|-quadrillions[-$2] # negative number [-−](\d+) moins |$1 # decimals "([-−]?\d+)[.,]" "$1| virgule" "([-−]?\d+[.,]0*)(\d+)" $1 |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ud:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 # masculine/feminine mf:.*un(e?) \1 BIF:(\D+) $(\1: franc burundais, francs burundais, de francs burundais, centime, centimes, un) CAD:(\D+) $(\1: dollar canadien, dollars canadiens, de dollars canadiens, cent, cents, un) CDF:(\D+) $(\1: franc congolais, francs congolais, de francs congolais, centime, centimes, un) CHF:(\D+) $(\1: franc suisse, francs suisses, de francs suisses, centime, centimes, un) DJF:(\D+) $(\1: franc de Djibouti, francs de Djibouti, de francs de Djibouti, centime, centimes, un) DZD:(\D+) $(\1: dinar algérien, dinars algériens, de dinars algériens, centime, centimes, un) EUR:(\D+) $(\1: euro, euros, d’euros, centime, centimes, un) GBP:(\D+) $(\1: livre sterling, livres sterling, de livres sterling, penny, pennies, une) GNF:(\D+) $(\1: franc guinéen, francs guinéens, de francs guinéens,,, un) HTF:(\D+) $(\1: gourde, gourde, de gourde, centime, centimes, une) KMF:(\D+) $(\1: franc des Comores, francs des Comores, de francs des Comores, centime, centimes, un) LBP:(\D+) $(\1: livre libanaise, livres libanaises, de livres libanaises,,, une) MAD:(\D+) $(\1: dirham marocain, dirhams marocains, de dirhams marocains, centime, centimes, un) MGA:(\D+) $(\1: ariary, ariarys, d’ariarys, iraimbilanja, iraimbilanja, un) MRO:(\D+) $(\1: ouguiya, ouguiya, d’ouguiya, khoum, khoums, un) MUR:(\D+) $(\1: roupie mauricienne, roupies mauriciennes, de roupies mauriciennes, cent, cents, une) RWF:(\D+) $(\1: franc rwandais, francs rwandais, de francs rwandais, centime, centimes, un) SCR:(\D+) $(\1: roupie seychelloise, roupies seychelloises, de roupies seychelloise, cent, cents, une) TND:(\D+) $(\1: dinar tunisien, dinars tunisiens, de dinars tunisiens, millime, millimes, un) USD:(\D+) $(\1: dollar américain, dollars américains, de dollars américains, cent, cents, un) VUV:(\D+) $(\1: vatu, vatus, de vatus,,, un) X[AO]F:(\D+) $(\1: franc CFA, francs CFA, de francs CFA, centime, centimes, un) XPF:(\D+) $(\1: franc Pacifique, francs Pacifique, de francs Pacifique, centime, centimes, un) "(GNF|LBP|VUV) ([-−]?[01](.0+)?)" $2$(\1:us) "(GNF|LBP|VUV) ([-−]?\d+0{6,})" $2$(\1:ud) "(GNF|LBP|VUV) ([-−]?\d+[.,]\d+)" $2$(\1:up) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:mf)$(\1:us) # un/une "([A-Z]{3}) ([-−]?\d*[02-9]1)([.,]00?)?" $2$(\1:mf)$(\1:up) # cent un/une mais pas cent onze "([A-Z]{3}) ([-−]?[0])([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+0{6,})([.,]00?)?" $2$(\1:ud) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:up) "((MGA|MRO) [-−]?\d+)[.,]0" $1 "((MGA|MRO) [-−]?\d+)[.,]2" $1 et |$(1)$(\2:ss) "((MGA|MRO) [-−]?\d+)[.,]4" $1 et |$(2)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]6" $1 et |$(3)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]8" $1 et |$(4)$(\2:sp) "((TND) [-−]?\d+)[.,](001)" $1 et |$(1)$(\2:ss) "((TND) [-−]?\d+)[.,](\d)" $1 et |$(\300)$(\2:sp) "((TND) [-−]?\d+)[.,](\d\d)" $1 et |$(\30)$(\2:sp) "((TND) [-−]?\d+)[.,](\d\d\d)" $1 et |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 et |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 et |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 et |$3$(\2:sp) == informal == (1\d)00 $1-cents (1\d)(\d\d) $1-cent[-$1] (.*) $1 == feminine == 1 une (.*) $1 == masculine == (.*) $1 == ordinal-feminine == 1 première == ordinal(-feminine|-masculine)? == 1 premier ([-−]?\d+) $(ordinal |$2) (.*)e \2ième # quatre etc. (.*)f \2vième # neuf (.*q) \2uième # cinq (.*) \2ième # others == ordinal-number-feminine == 1 1ʳᵉ == ordinal-number(-feminine|-masculine)? == 1 1ᵉʳ (\d+) \2ᵉ == help == "" $(1), $(2), $(3)\n$(help feminine)$(help masculine)$(help ordinal)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number-feminine)$(help ordinal-number-masculine)$(help informal) (informal) \1: $(\1 1100), $(\1 1200), $(\1 1300)\n (feminine|masculine|ordinal(-feminine|-masculine|-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 náid 1 aon 2$ dó 2 dhá 3 trí 4 ceathair 5 cúig 6 sé 7 seacht 8 ocht 9 naoi 10 deich 12 dó dhéag 1(\d) $1 déag (\d)([18]) $(\10) a h$2 2(\d) fiche[ a $1] 3(\d) tríócha[ a $1] 4(\d) ceathracha[ a $1] # 4(\d) daichead[ a $1] # alternative 5(\d) caoga[ a $1] 6(\d) seasca[ a $1] ([78])(\d) $1ó[ a $2] 9(\d) nócha[ a $1] (\d)(\d\d) $1 céad[ $2] (\d{1,3})(\d\d\d) $1 míle[ $2] (\d{1,3})(\d{6}) $1 milliún$(:\2)$2 (\d{1,3})(\d{9}) $1 billiún$(:\2)$2 (\d{1,3})(\d{12}) $1 trilliún$(:\2)$2 # currency # unit/subunit u:([^,]*),([^,]*) \1 s:([^,]*),([^,]*) \2 EUR:(.) $(\1: euro, cent) GBP:(.) $(\1: punt steirling, pingin) USD:(.) $(\1: dollar, cent) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:s) == ordinal == # chapter one -> caibidil a haon ([18]) a h$1 (\d|10) a $1 ([23]0) $1 ([4-9]0) $1dú ([234])(\d) $(ordinal \2) is $(\10) (\d\d) a $1 (.*) $1 == ordinal-number == (.*) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal)$(help ordinal-number)currency \(for example, EUR\): $(EUR 2.5)\n (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 cero 1$ un 1 un 2 dous 3 tres 4 catro 5 cinco 6 seis 7 sete 8 oito 9 nove 10 dez 11 once 12 doce 13 trece 14 catorce 15 quince 1(\d) deza$1 20 vinte 30 trinta 40 corenta 50 cincuenta 60 sesenta 70 setenta 80 oitenta 90 noventa (\d)(\d) $(\10) e $2 1(\d\d) cen[to $1] (\d\d) $(\100) $2 (\d)(\d\d) $1centos[ $2] 1(\d{3}) mil[ $1] (\d{1,3})(\d{3}) $1 mil[ $2] 1(\d{6}) un millón[ $1] (\d{1,6})(\d{6}) $1 millóns[ $2] 1(\d{12}) un billón[ $1] (\d{1,6})(\d{12}) $1 billóns[ $2] 1(\d{18}) un trillón[ $1] (\d{1,6})(\d{18}) $1 trillóns[ $2] (\d{7,})(\d{18}) $1 de trillóns[ $2] # negative number [-−](\d+) menos |$1 # decimals ([-−]?\d+)[.] $1| punto ([-−]?\d+)[,] $1| coma ([-−]?\d+[.,])([^0]\d) $1| |$2 ([-−]?\d+[.,])(\d)(\d)(\d) |$1 |$2| |$3| |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 ARS:(\D+) $(\1: peso arxentino, pesos arxentinos, centavo, centavos) BOB:(\D+) $(\1: boliviano, bolivianos, centavo, centavos) BZD:(\D+) $(\1: dólar belizense, dólares belizenses, centavo, centavos) CEC:(\D+) $(\1: peso convertíbel, pesos convertíbeis, centavo, centavos) CHF:(\D+) $(\1: franco suízo, francos suízos, céntimo, céntimos) CLP:(\D+) $(\1: peso chileno, pesos chilenos, centavo, centavos) CNY:(\D+) $(\1: iuan renminbi, iuans renminbi, fen, fen) COP:(\D+) $(\1: peso colombiano, pesos colombianos, centavo, centavos) CRC:(\D+) $(\1: colón costarriqueño, colóns costarriqueños, céntimo, céntimos) DOP:(\D+) $(\1: peso dominicano, pesos dominicanos, centavo, centavos) ESP:(\D+) $(\1: peseta, pesetas, céntimo, céntimos) EUR:(\D+) $(\1: euro, euros, céntimo, céntimos) GBP:(\D+) $(\1: libra esterlina, libras esterlinas, penique, peniques) GTQ:(\D+) $(\1: quetzal, quetzais, centavo, centavos) HNL:(\D+) $(\1: lempira, lempiras, centavo, centavos) JPY:(\D+) $(\1: ien, iens sen, sen) MXN:(\D+) $(\1: peso mexicano, pesos mexicanos, centavo, centavos) NIO:(\D+) $(\1: córdoba, córdobas, centavo, centavos) PEN:(\D+) $(\1: sol, soles, centavo, centavos) PYG:(\D+) $(\1: guaraní, guaranís, céntimo, céntimos) USD:(\D+) $(\1: dólar estadounidense, dólares estadounidenses, centavo, centavos) UYU:(\D+) $(\1: peso uruguaio, pesos uruguaios, centésimo, centésimos) VEF:(\D+) $(\1: bolívar forte, bolívares fortes, céntimo, céntimos) # masculine to feminine conversion of "un" after millions, # if "as?$" matches currency name f:(.*ill)(.*),(.*) \1$(f:\2,\3) # don't modify un in millions f:(.*un)([^h].*,|,)(.*as?) $(f:\1ha\2\3) # un libra → unha libra f:(.*)dous(.*,|,)(.*as?) $(f:\1dúas\2\3) # dous libras → dúas libra f:(.*)douscentos(.*,|,)(.*as?) $(f:\1duascentas\2\3) # douscentos libras → duascentas libras f:(.*ent)o(s.*),(.*as?) $(f:\1a\2,\3) # trescentos libras → trescentas libras f:(.*),(.*) \1\2 "([A-Z]{3}) ([-−]?1)([.,]00?)?"$(f:|$2,$(\1:us)) "([A-Z]{3}) ([-−]?\d+0{6,})([.,]00?)?" $2 de$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(f:|$2,$(\1:up)) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 con |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 con |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 con |$3$(\2:sp) # ordinal feminine:(.*un) \1ha feminine:(.*) \1 == feminine == (.*) $(feminine:|$1|) == masculine == 1 un (.*) $1 == ordinal-masculine == (.*) $(ordinal \1) == ordinal == 1 primeiro 2 segundo 3 terceiro 4 cuarto 5 quinto 6 sexto 7 sétimo 8 oitavo 9 noveno 10 décimo 11 undécimo 12 duodécimo 20 vixésimo 30 trixésimo 40 cuadraxésimo 50 quincuaxésimo 60 sesaxésimo 70 septuaxésimo 80 octoxésimo 90 nonaxésimo (\d)(\d) $(ordinal \10) $(ordinal \2) 100 centésimo 200 ducentésimo 300 tricentésimo 400 cuadrinxentésimo 500 quinxentésimo 600 sexcentésimo 700 septinxentésimo 800 octinxentésimo 900 noninxentésimo (\d)(\d\d) $(ordinal \100) $(ordinal \2) 1(\d{3}) milésimo[ $(ordinal \1)] (\d{1,3})(\d{3}) $1 milésimo[ $(ordinal \2)] 1(\d{6}) millonésimo[ $(ordinal \1)] (\d{1,3})(\d{6}) $1 millonésimo[ $(ordinal \2)] 1(\d{9}) milmillonésimo[ $(ordinal \1)] (\d{1,3})(\d{9}) $1 milmillonésimo[ $(ordinal \2)] == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal-masculine \1)) (.*)o\b(.*) $(ordinal-feminine \1a\2) (.*) \1 == ordinal-masculine-adjective == ([-−]?\d+) $(ordinal-masculine-adjective $(ordinal-masculine \1)) (.*) \1 # ordinal abbreviation == (ordinal)-number(-feminine|-masculine|-masculine-adjective)? == ([-−]?\d+) \3$(ordinal-number $(\1\2 \3)) .*a .ª .*o .º == help == "" $(1)|, $(2), $(3)\n$(\0 feminine)$(\0 masculine)$(\0 ordinal-number-masculine)$(\0 ordinal-number-masculine-adjective)$(\0 ordinal-number-feminine)$(\0 ordinal-feminine)$(\0 ordinal-masculine)$(\0 ordinal-masculine-adjective) (feminine|masculine|ordinal(-number)?(-feminine|-masculine)?(-adjective)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 אפס 1 אחת 2 שתיים 3 שלוש 4 ארבע 5 חמש 6 שש 7 שבע 8 שמונה 9 תשע 10 עשר 12 שתים-עשרה 1(\d) $1-עשרה 20 עשרים 50 חמישים 60 שישים 80 שמונים (\d)0 $1ים (\d)(\d) $(\10) ו$2 # separator after 1-2 hundred(s) hs1:20 " ו" # מאה ועשרים hs1:(\d\d) $(hs:\1) # separator after 3+ hundreds hs:0+ # מאה hs:[01]\d " ו" # מאה ועשר hs:\d+ " " # מאה שלושים וחמש 1(\d\d) מאה$(hs1:\1)$1 2(\d\d) מאתיים$(hs1:\1)$1 (\d)(\d\d) $(df:\1) מאות$(hs:\2)$2 # separator after thousands+ ts:0+ # אלף ts:0+\d\d " ו" # אלף ושלושים ts:\d+ " " # אלף מאה שלושים 1(\d{3}) אלף$(ts:\1)$1 2(\d{3}) אלפיים$(ts:\1)$1 ([3-9]|10)(\d{3}) $(dm2:\1) אלפים$(ts:\2)$2 (\d{1,3})(\d{3}) $(m:$1) אלף$(ts:\2)$2 1(\d{6}) מיליון$(ts:\1)$1 2(\d{6}) שני מיליונים$(ts:\1)$1 ([3-9]|10)(\d{6}) $(m:$1) מיליונים$(ts:\2)$2 (\d{1,3})(\d{6}) $(m:$1) מיליון$(ts:\2)$2 1(\d{9}) מיליארד$(ts:\1)$1 2(\d{9}) שני מיליארדים$(ts:\1)$1 ([3-9]|10)(\d{9}) $(m:$1) מיליארדים$(ts:\2)$2 (\d{1,3})(\d{9}) $(m:$1) מיליארד$(ts:\2)$2 1(\d{12}) טריליון$(ts:\1)$1 2(\d{12}) שני טריליונים$(ts:\1)$1 ([3-9]|10)(\d{12}) $(m:$1) טריליונים$(ts:\2)$2 (\d{1,3})(\d{12}) $(m:$1) טריליון$(ts:\2)$2 1(\d{15}) קוודראליון$(ts:\1)$1 2(\d{15}) שני קוודראליונים$(ts:\1)$1 ([3-9]|10)(\d{15}) $(m:$1) קוודראליונים$(ts:\2)$2 (\d{1,3})(\d{15}) $(m:$1) קוואדראליון$(ts:\2)$2 1(\d{18}) קווינטיליון$(ts:\1)$1 2(\d{18}) שני קווינטיליונים$(ts:\1)$1 ([3-9]|10)(\d{18}) $(m:$1) קווינטיליונים$(ts:\2)$2 (\d{1,3})(\d{18}) $(m:$1) קווינטיליון$(ts:\2)$2 1(\d{21}) סקסטיליון$(ts:\1)$1 2(\d{21}) שני סקסטיליונים$(ts:\1)$1 ([3-9]|10)(\d{21}) $(m:$1) סקסטיליונים$(ts:\2)$2 (\d{1,3})(\d{21}) $(m:$1) סקסטיליון$(ts:\2)$2 1(\d{24}) ספטיליון$(ts:\1)$1 2(\d{24}) שני ספטיליונים$(ts:\1)$1 ([3-9]|10)(\d{24}) $(m:$1) ספטיליונים$(ts:\2)$2 (\d{1,3})(\d{24}) $(m:$1) ספטיליון$(ts:\2)$2 # negative number [-−](\d+) מינוס |$1 # decimals "([-−]?\d+)[.,]" $1| נקודה "([-−]?\d+[.,])([1-9]\d)" $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # feminine->masculine correction, as all numbers are given for feminine gender m:(.*)אחת \1אחד m:(.*)שתיים \1שניים m:(.*)חמש \1חמישה m:(.*)שש \1שישה m:(.*)(שלוש|ארבע|שבע|תשע|עשר) \1\2ה m:(.*)אחת-עשרה \1אחד-עשר m:(.*)שתים-עשרה \1שנים-עשר m:(.*)חמש-עשרה \1חמישה-עשר m:(.*)שש-עשרה \1שישה-עשר m:(.*)(שלוש|ארבע|שבע|תשע)-עשרה \1\2ה-עשר [fm]:(.*) \1 # numbers dependent on what they count df:(.*)2 $1שתי dm:1 אחד dm:2 שני # more rarely used dm2:8 שמונת dm2:(\d|10) $1ת dm2:(.*) $(dm:\1) d([fm]):(1(0{24}|0{21}|0{18}|0{15}|0{12}|0{9}|0{6}|0{3})) $(m:$2) d([fm]):20{24} שני ספטיליוני d([fm]):(\d{1,3})0{24} $(m:$2) ספטיליוני d([fm]):20{21} שני סקסטיליוני d([fm]):(\d{1,3})0{21} $(m:$2) סקסטיליוני d([fm]):20{18} שני קווינטיליוני d([fm]):(\d{1,3})0{18} $(m:$2) קווינטיליוני d([fm]):20{15} שני קוודראליוני d([fm]):(\d{1,3})0{15} $(m:$2) קוודראליוני d([fm]):20{12} שני טריליוני d([fm]):(\d{1,3})0{12} $(m:$2) טריליוני d([fm]):20{9} שני מיליארדי d([fm]):(\d{1,3})0{9} $(m:$2) מיליארדי d([fm]):20{6} שני מיליוני d([fm]):(\d{1,3})0{6} $(m:$2) מיליוני d([fm]):20{3} אלפיים d([fm]):(\d{1,3})0{3} $(dm2:\2) אלפים d([fm]):(.*) $(\1:$2) # numbers independent on what they count i([fm]):(.*)[.,](.*) $(\1:$2) נקודה i([fm]):(.*) $(\1:$2) # currency # gender unit, gender subunit, unit singular, unit, plural, subunit singular, subunit, plural us(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 $(\1:\6) up(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \3 ss.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 $(\1:\6) sp.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \5 # "mm" means masculine unit and masculine subunit CHF:(.+),(.+) $(\1mm:פרנק שוויצרי,פרנקים שוויצריים,סנט,סנטים,\2) CNY:(.+),(.+) $(\1mm:יואן,יואנים,פן,פנים,\2) EUR:(.+),(.+) $(\1mm:אירו,אירו,סנט,סנטים,\2) GBP:(.+),(.+) $(\1fm:לירה סטרלינג,לירות סטרלינג,פני,פנים,\2) ILS:(.+),(.+) $(\1mf:שקל,שקלים,אגורה,אגורות,\2) JPY:(.+),(.+) $(\1mm:יין,יינים,סן,סנים,\2) USD:(.+),(.+) $(\1mm:דולר ארה"ב,דולרים ארה"ב,סנט,סנטים,\2) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $(\1:us,|$(dm:\2)) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $(\1:up,|$(dm:\2)) "(CNY [-−]?\d+)[.,]10?" $1| ז'יאו אחד "(CNY [-−]?\d+)[.,](\d)0?" $1| $2| ז'יאו "(CNY [-−]?\d+[.,]\d)1" $1| $2| פן "(CNY [-−]?\d+[.,]\d)(\d)" $1| $2| פן "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1| ו$(\2:ss,$(1)) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1| ו$(\2:sp,$(\30)) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1| ו$(\2:sp,$3) # ordinal numbers: in hebrew, they depend on gender # transform a number to a feminine ordinal "ordinal-masculine (\d+)" $(ordm:\1) ordm:1 ראשון ordm:2 שני ordm:3 שלישי ordm:4 רביעי ordm:5 חמישי ordm:6 שישי ordm:7 שביעי ordm:8 שמיני ordm:9 תשיעי ordm:10 עשירי # transform a number to a masculine ordinal "ordinal-feminine (\d+)" $(ordf:\1) ordf:1 ראשונה ordf:2 שניה ordf:([3-9]|10) $(ordm:\1)ת # other numbers ord([fm]):(\d+) $(\1:$2) # from the end ;) "ordinal-(f|m)(eminine|asculine) [-−]?(\d+)" $(ord\1:\2) מהסוף # ordinal abbreviation: no such thing "ordinal-number(-feminine|-masculine)? ([-−]?\d+)" $(ordinal\1 \2) # masculine assumption "ordinal ([-−]?\d+)" $(ordinal-masculine \1) help פונקציות נוספות:\nord, ordm \(מספר סידורי זכר, כגון "ראשון"\)\nordf \(מספר סידורי נקבה, כגון "ראשונה"\)
# # Regular number to text transducer for Serbian (Cyrillic) written in Soros # Copyright (c) Goran Rakic
2009. # Modified and translated for Croatian by Mihovil Stanic
2014. # # Released under Creative Commons 3.0 Attribution - Share Alike license # and relicensed under GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Visit http://numbertext.org for more info on Soros language and syntax # (\d{1,3})\.([\d.,]+) $(\1\2) ^0 nula 1 jedan 2 dva 3 tri 4 četiri 5 pet 6 šest 7 sedam 8 osam 9 devet 10 deset 11 jedanaest 14 četrnaest 16 šesnaest 1(\d) $1naest 4(\d) četrdeset[ $1] 5(\d) pedeset[ $1] 6(\d) šezdeset[ $1] 9(\d) devedeset[ $1] (\d)(\d) $1deset[ $2] 1(\d\d) sto[ $1] 2(\d\d) dvjesto[ $1] 3(\d\d) tristo[ $1] (\d)(\d\d) $1sto[ $2] 1(\d\d\d) tisuću[ $1] 2(\d\d\d) dvije tisuće[ $1] ([34])(\d\d\d) $1 tisuće[ $2] (\d{0,1})1(\d)(\d\d\d) $(\11\2) tisuća[ $3] (\d{1,2})1(\d\d\d) $(\10) jedna tisuća[ $2] (\d{1,2})2(\d\d\d) $(\10) dvije tisuće[ $2] (\d{1,2})([34])(\d\d\d) $(\10) $2 tisuće[ $3] (\d{1,3})(\d\d\d) $1 tisuća[ $2] 1(\d{6}) milion[ $1] (\d{0,4})1(\d)(\d{6}) $(\11\2) miliona[ $3] (\d{1,5})1(\d{6}) $(\10) jedan milion[ $2] (\d{1,3})(\d{6}) $1 miliona[ $2] 1(\d{9}) milijarda[ $1] 2(\d{9}) dvije milijarde[ $1] ([34])(\d{9}) $1 milijarde[ $2] (\d{1,2})0(\d{9}) $(\10) milijardi[ $2] (\d{0,1})1(\d)(\d{9}) $(\11\2) milijardi[ $3] (\d{1,2})1(\d{9}) $(\10) jedna milijarda[ $2] (\d{1,2})2(\d{9}) $(\10) dvije milijarde[ $2] (\d{1,2})([34])(\d{9}) $(\10) $2 milijarde[ $3] (\d{1,3})(\d{9}) $1 milijarde[ $2] 1(\d{12}) bilijun[ $1] (\d{0,4})1(\d)(\d{12}) $(\11\2) bilijuna[ $3] (\d{1,5})1(\d{12}) $(\10) jedan bilijun[ $2] (\d{1,6})(\d{12}) $1 bilijuna[ $2] 1(\d{18}) trilijun[ $1] (\d{0,4})1(\d)(\d{18}) $(\11\2) trilijuna[ $3] (\d{1,5})1(\d{18}) $(\10) jedan trilijun[ $2] (\d{1,6})(\d{18}) $1 trilijuna[ $2] 1(\d{24}) kvadrilijun[ $1] (\d{0,4})1(\d)(\d{24}) $(\11\2) kvadrilijuna[ $3] (\d{1,5})1(\d{24}) $(\10) jedan kvadrilijun[ $2] (\d{1,6})(\d{24}) $1 kvadrilijuna[ $2] 1(\d{30}) kvintilijun[ $1] (\d{0,4})1(\d)(\d{30}) $(\11\2) kvintilijuna[ $3] (\d{1,5})1(\d{30}) $(\10) jedan kvintilijun[ $2] (\d{1,6})(\d{30}) $1 kvintilijuna[ $2] 1(\d{36}) sekstilijun[ $1] (\d{0,4})1(\d)(\d{36}) $(\11\2) sekstilijuna[ $3] (\d{1,5})1(\d{36}) $(\10) jedan sekstilijun[ $2] (\d{1,6})(\d{36}) $1 sekstilijuna[ $2] # negative number [-−] minus [-−](\d+) minus |$1 # Decimal code by https://twitter.com/_uranium_ "([-−]?\d+)[.,]" $1| zarez "([-−]?\d+[.,])([^0]\d)" $1 $2 "([-−]?\d+[.,]\d*[1-9]?)0+$" $1 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1 |$2 # currency # unit/subunit us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 HRK:(\D+) $(\1: kuna, kune, kuna, lipa, lipe, lipa) #ff DKK:(\D+) $(\1: kruna, krune, kruna, ora, ore, ora) #ff SEK:(\D+) $(\1: kruna, krune, kruna, ora, ore, ora) #ff CZK:(\D+) $(\1: kruna, krune, kruna, haler, halera, halera) #fm HUF:(\D+) $(\1: forinta, forinte, forinti, filer, filera, filera) #fm GBP:(\D+) $(\1: funta, funte, funti, peni, penija, penija) #fm BAM:(\D+) $(\1: konvertibilna marka, konvertibilne marke, konvertibilnih marki, fening, feninga, feninga) #fm BGN:(\D+) $(\1: lev, leva, leva, stotinka, stotinke, stotinki) #mf RSD:(\D+) $(\1: dinar, dinara, dinara, para, pare, para) #mf RON:(\D+) $(\1: leu, leu, leu, ban, bana, bana) #mm CHF:(\D+) $(\1: franak, franka, franaka, centim, centima, centima) #mm EUR:(\D+) $(\1: euro, eura, eura, cent, centa, centa) #mm USD:(\D+) $(\1: dolar, dolara, dolara, cent, centa, centa) #mm PLN:(\D+) $(\1: zlot, zlota, zlota, groš, groša, groša) #mm # Covers cases where currency sign is after numbers or different position "(.*) kn" $(HRK \1) "(.*) €" $(EUR \1) "(.*)€" $(EUR \1) "€(.*)" $(EUR \1) "€ (.*)" $(EUR \1) "(.*) Ft" $(HUF \1) "(.*) din." $(RSD \1) "\$(.*)" $(USD \1) "\$ (.*)" $(USD \1) "(.*) \$" $(USD \1) "KM(.*)" $(BAM \1) "£(.*)" $(GBP \1) "(.*) HRK" $(HRK \1) "(.*) DKK" $(DKK \1) "(.*) SEK" $(SEK \1) "(.*) CZK" $(CZK \1) "(.*) HUF" $(HUF \1) "(.*) GBP" $(GBP \1) "(.*) BAM" $(BAM \1) "(.*) BGN" $(BGN \1) "(.*) RSD" $(RSD \1) "(.*) RON" $(RON \1) "(.*) CHF" $(CHF \1) "(.*) EUR" $(EUR \1) "(.*) USD" $(USD \1) "(.*) PLN" $(PLN \1) "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([-−]?1)([.,]00?)?" jedna$(\1:us) #female, for 1 "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([-−]?2)([.,]00?)?" dvije$(\1:up) #female, for 2 "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([02-9])1([.,]00?)?" $(\20) jedna$(\1:us) #female, for numbers from 21-91 ending with 1 "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([02-9])2([.,]00?)?" $(\20) dvije$(\1:up) #female, for numbers from 22-92 ending with 2 "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([-−]?\d*)([02-9])1([.,]00?)?" $(\200) $(\30) jedna$(\1:us) #female, for numbers >100 ending with 1 but not 11 "(HRK|DKK|SEK|CZK|HUF|GBP|BAM) ([-−]?\d*)([02-9])2([.,]00?)?" $(\200) $(\30) dvije$(\1:up) #female, for numbers >100 ending with 2 but not 12 "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?\d*[02-9]1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?[234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d*[02-9][234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:ug) "((HRK|DKK|SEK|BGN|RSD) [-−]?\d+)[.,]([02-9])1" $1 $(\30) jedna $(\2:ss) #decimal, female, ending with 1 but not 11 "((HRK|DKK|SEK|BGN|RSD) [-−]?\d+)[.,]([02-9])2" $1 $(\30) dvije $(\2:sp) #decimal, female, ending with 2 but not 12 "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9]1)" $1 |$3$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9][234])" $1 |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sg) == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 nulla 1 egy 2$ kettő 2 két 3 három 4 négy 5 öt 6 hat 7 hét 8 nyolc 9 kilenc 10 tíz 1(\d) tizen$1 20 húsz 2(\d) huszon$1 3(\d) harminc$1 4(\d) negyven$1 5(\d) ötven$1 6(\d) hatvan$1 7(\d) hetven$1 8(\d) nyolcvan$1 9(\d) kilencven$1 1(\d\d) száz$1 (\d)(\d\d) $1száz$2 11(\d{2}) ezeregy$(1\1) 1(\d{3}) ezer$1 (\d{1,3})(\d{3}) $1ezer[-$2] (\d{1,3})(\d{6}) $1millió[-$2] (\d{1,3})(\d{9}) $1milliárd[-$2] (\d{1,3})(\d{12}) $1billió[-$2] (\d{1,3})(\d{15}) $1billiárd[-$2] (\d{1,3})(\d{18}) $1trillió[-$2] (\d{1,3})(\d{21}) $1trilliárd[-$2] # negative numbers [-−](\d+) mínusz |$1 # decimals "([-−]?\d+)[.,](\d)" |$1| egész |$2 tized "([-−]?\d+)[.,](\d\d)" |$1| egész |$2 század "([-−]?\d+)[.,](\d{3})" |$1| egész |$2 ezred "([-−]?\d+)[.,](\d)(\d)(\d)(\d)" |$1| egész |$2| |$3| |$4| |$5| "([-−]?\d+[.,]\d+)(\d)" $1 |$2| # currency # unit/subunit u:([^,]*),([^,]*) \1 s:([^,]*),([^,]*) \2 AUD:(.) $(\1: ausztrál dollár, cent) BGN:(.) $(\1: bolgár leva, sztotinka) BRL:(.) $(\1: brazil real, centavo) CAD:(.) $(\1: kanadai dollár, cent) CHF:(.) $(\1: svájci frank, rappen) CNY:(.) $(\1: kínai jüan, fen) CZK:(.) $(\1: cseh korona, haléř) DKK:(.) $(\1: dán korona, øre) EEK:(.) $(\1: észt korona, sent) EUR:(.) $(\1: euró, cent) GBP:(.) $(\1: font sterling, penny) HKD:(.) $(\1: hongkongi dollár, cent) HRK:(.) $(\1: horvát kuna, lipa) HUF:(.) $(\1: forint, fillér) ISK:(.) $(\1: izlandi korona, eyrir) JPY:(.) $(\1: japán jen, szen) KRW:(.) $(\1: dél-koreai von, cson) LTL:(.) $(\1: litván litas, centas) LVL:(.) $(\1: lett lat, santīm) MXN:(.) $(\1: mexikói peso, centavo) NOK:(.) $(\1: norvég korona, øre) NZD:(.) $(\1: új-zélandi dollár, cent) PLN:(.) $(\1: lengyel złoty, grosz) RON:(.) $(\1: román lej, bani) RSD:(.) $(\1: szerb dinár, para) RUB:(.) $(\1: orosz rubel, kopejka) SEK:(.) $(\1: svéd korona, öre) SGD:(.) $(\1: szingapúri dollár, cent) TRY:(.) $(\1: török líra, kuruş) UAH:(.) $(\1: ukrán hrivnya, kopijka) USD:(.) $(\1: USA-dollár, cent) ZAR:(.) $(\1: dél-afrikai rand, cent) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:s) # Article a/az (number name) "article (cardinal |formal ){2}(([a-zA-Z]+ )*1\d{2}([.,]\d*)?)" az $(formal \2) "article (cardinal |ordinal )(([a-zA-Z]+ )*1(\d{3})*([.,]\d*)?)" az $(\1\2) "article (cardinal |ordinal )(([a-zA-Z]+ )*5.*)" az $(\1\2) "article (cardinal |ordinal )([^-].*)" a $(\1\2) # Article a/az + optional cardinal/ordinal + suffixation "article ((cardinal |ordinal )?(-[^0-9]+) [{\(\[]?(\d+|[a-zA-Z])[}\)\]]?)" $(article $(\1)) # cardinal/ordinal + suffixation "(cardinal )(-[^0-9]+) ([{\(\[]?(\d+)[}\)\]]?)" $(\1$(\2 \4)) "(ordinal )(-[^0-9]+) ([{\(\[]?(\d+)[}\)\]]?)" $(\1$(\2 \4.)) "(cardinal |ordinal )(\d+)[.]?-([a-záéóöőüű]*)$" $(fix-grammar $(\1\2)|\3) == fix-grammar == (.*)elsői \1elseji (.*)elsőei \1elsejei (.*)elsőe(.*) \1első\2 (.*)első(j.*) \1else\2 (.*)hároma(t|s) \1hárma\2 (.*)húszsz(.*) \1hússz\2 (.*)gygy(.*) \1ggy\2 (.*) \1 # Article a/az (number, month names and other words) == article == "(-[a-záéö]* .*|[a-z][-a-z]*ive .*)" $(article $(\1)) # for example, "article -ban október" -> "az októberben" ((i|v|l(v?i{0,3}|i[vx])|d(xc)?[ilxv]*|m(cm)?[cdilxv]*)[.](-.*)?) az \1 # Roman numbers ((I|V|L(V?I{0,3}|I[VX])|D(XC)?[ILXV]*|M(CM)?[CDILXV]*)[.](-.*)?) az \1 # ROMAN NUMBERS ((iii?|iv|vi{1,3}|ix|(x{1,3}|xl|lx{1,3}|xc)(i{0,3}|vi{0,3}|ix)|(c{1,3}|cd|dc{1,3})[ilxv]*|mmm?[dilxv]*)[.](-.*)?) a \1 # Roman numbers II. ((III?|IV|VI{1,3}|IX|(X{1,3}|XL|LX{1,3}|XC)(I{0,3}|VI{0,3}|IX)|(c{1,3}|CD|DC{1,3})[ILXV]*|MMM?[DILXV]*)[.](-.*)?) a \1 # ROMAN NUMBERS II. ([{\(\[]?(1(\d{3}|\d{6})*|[aefilmnorsuxyAEFILMNORSUXY])[}\)\]]?(-.*)?) az \1 # numbers and 1-letter indices ([{\(\[]?5.*) az \1 # numbers ([aáeéiíoóöőuúüűAÁEÉIÍOÓÖŐUÚÜŰ].*) az \1 (.*) a \1 == ordinal == 1 első 2 második "(([a-zA-Z]+ )*[-−]?\d+)" $(ordinal $1) (.*)nulla \1nulladik (.*)egy \1egyedik (.*)kettő \1kettedik (.*)három \1harmadik (.*)négy \1negyedik (.*)öt \1ötödik (.*)hat \1hatodik (.*)hét \1hetedik (.*)nyolc \1nyolcadik (.*)kilenc \1kilencedik (.*)tíz \1tizedik (.*)húsz \1huszadik (.*)harminc \1harmincadik (.*)(negy|öt|het|kilenc)ven \1\2venedik (.*)(hat|nyolc)van \1\2vanadik (.*)száz \1századik (.*)ezer \1ezredik (.*)illió \1illiomodik (.*)illiárd \1illiárdodik == formal == "(([a-zA-Z]+ )*[-−]?\d+([.,]\d*)?)" $(formal |$1) (|.*-)((száz|ezer).*) $(formal \1egy\2) (.*)két(.*) $(formal \1kettő\2) (.*) \1 == year == # no hyphen in numbers "(([a-zA-Z]+ )*[-−]?\d+)" $(year |$1) (.*)-(.*) $(year \1\2) (.*) \1 == cardinal == (.*) $1 == ordinal-number == (.*) \1. == text == (\d|10) $1 (\d{2,4}) \1 (\d{2,3})(\d{3}) \1 ezer[ $(text \2)] (\d{1,3})(\d{6}) \1 millió[ $(text \2)] (\d{1,4})(\d{9}) \1 milliárd[ $(text \2)] (\d{1,4})(\d{12}) \1 billió[ $(text \2)] (\d{1,4})(\d{15}) \1 billiárd[ $(text \2)] # suffix functions for numbers, dates, letters and parenthesized references # # canonical and localized suffix function names # # for example: # # accusative 2 -> 2-t # -t 2 -> 2-t # -t 3 -> 3-at # -t 4 -> 4-et # -t 5 -> 5-öt # -t 6 -> 6-ot # -ban a) -> a)-ban # -ban b) -> b)-ben == database == "" :ablative:-tól-től:accusative:-at-et-ot-öt-t:adessive:-nál-nél:adjective:-i-ji:allative:-hoz-hez-höz:attribution-adjective:-as-es-os-ös:dative:-nak-nek:delative:-ról-ről:elative:-ból-ből:fraction-nominative:-ad-ed-od-öd:illative:-ba-be:inessive:-ban-ben:instrumental:-val-vel:multiplicative:-szor-szer-ször:multiplicative-adjective:-szoros-szeres-szörös:possessive:-a-e-je:possessive-ablative:-ától-étől-jétől:possessive-adjective:-ai-ei-jei:possessive-inessive:-ában-ében:possessive-superessive:-án-én:possessive-terminative:-áig-éig-jéig:sublative:-ra-re:superessive:-on-en-ön:terminative:-ig:translative:-vá-vé: # get suffixed form using the following canonical names # # for example, "accusative 5" -> "5-öt" == ([a-z][-a-z]*ive) == ([^:]*) $($(\1 $(database)) \2) .*:\1:(-[^-:]*).* \2 # get suffixed form using the alternative suffix variants # by converting them to the preferred (first) variant # # for example "-et" -> "-at", then # "-at 5" -> "5-öt" == (-[a-z]*[eéöő][a-zéöő]*|-t) == ([^:]*) $($(\1 $(database)) \2) .*:(-[^-:]+)(-[^-:]+)*\1.* \2 # replace localized function name with their canonical-name in an input list == canonical-name == "([^:]* )?(-[a-zéáóöő]+)( [^:]*)?" \1$(canonical-name \2 $(database))\3 (-[a-zéáóöő]+).*:([a-z]+(-[a-z]+)?):[^:]*\1[-,:].* \2 == -a == "(1|.* 1)" \1-je "(2|.* 2)" \1-a == -ai == "(1|.* 1)" \1-jei "(2|.* 2)" \1-ai == -i == "(1|.* 1)" \1-ji == -án == "(1|.* 1)" \1-jén "(2|.* 2)" \1-án == -áig == "(1|.* 1)" \1-jéig "(2|.* 2)" \1-áig == -ától == "(1|.* 1)" \1-jétől "(2|.* 2)" \1-ától == -at == 1[.] 1.-t (\d*)2 \12-t 2[.] 2.-at (\d*)5 \15-öt (\d*)6 \16-ot == -d == ([{\(\[]?(.*[^0]0{6,8}|.*[^0]0{12,14})[}\)\]]?) \1-od ([{\(\[]?[ahkoquAHKOQU][}\)\]]?) \1-ad ([{\(\[]?[bcdefgijlmnprstvwxzBCDEFGIJLMNPRSTVWXZ][}\)\]]?) \1-ed == -([ds]) == ([{\(\[]?.*2[}\)\]]?) \2-e\1 ([{\(\[]?[yY][.]?[}\)\]]?) \2-o\1 == -([dst]) == ([{\(\[]?.*5[}\)\]]?) \2-ö\1 ([{\(\[]?(0|.*2|.*[^0]0{6,8}|.*[^0]0{12,14}|[abcdeghijkopqtuvwyzABCDEGHIJKOPQTUVWYZ][.]?)[}\)\]]?) \2-\1 ([{\(\[]?(.*6|.*[^0]0{9,11}|.*[^0]0{15,17})[}\)\]]?) \2-o\1 ([{\(\[]?(\d+|[a-zA-Z])[}\)\]]?) $(-a\1 \2) == -dik == (.?(\d+|[a-zA-Z][.]?)[}\)\]]?) $(-d \1)ik == -hoz == ((.*2|.*5|1[.])[}\)\]]?) \1-höz == -szoros == (.*5[}\)\]]?) \1-szörös == -szor == ([{\(\[]?(\d+|[a-zA-Z])[}\]\)]?) $(-szor $(-szoros \1)) (.*-sz.r).s \1 # MONTHS == -(a|á)(ban|tól|ig)? == ((jan|febr)uár) \3j\1\2 == -(á)?(a|ban|tól|ig) == ((jan|febr)uár|március|április|május|jú(n|l)ius|augusztus) \3\1\2 # convert optional "á" and vowels of "ban", "tól", "ig" to # "-ben", "-től", "-ig" using prefix "-on", and remove dash ((szeptem|októ|novem|decem)ber) \3$(remove-dash $(-on -\1))$(remove-dash $(-on -\2)) == abbreviation == (jan|febr|márc|ápr|máj|jún|júl|aug|szept|okt|nov|dec).* \1. == remove-dash == -(.*) \1 # DAYS == -ig == szerda szerdáig ((.*\d|[{\(\[]?[a-zA-Z])[}\)\]]?) \1-ig (.*\D) \1ig == -tól == szerda szerdától (hétfő|kedd|csütörtök|péntek) \1től (szombat|vasárnap) \1tól == -on == hétfő hétfőn (kedd|péntek) \1en szerda szerdán csütörtök csütörtökön szombat szombaton vasárnap vasárnap # no suffix in dates (.*5[}\)\]]?) \1-ön ([{\(\[]?(0|.*2|.*[^0]0{6,8}|.*[^0]0{12,14}|[abcdeghijkopqtuvwzABCDEGHIJKOPQTUVWZ][.]?)[}\)\]]?) \1-n (.?(\d+|[flmnrsxyFLMNRSXY][.]?)[}\)\]]?) $(-on \1) == -val == # ordinal (1[.]) \1-vel (2[.]) \1-kal (.*([368]|[2368]0|\d00|\d0{6,})[.]) \1-kal (.*([14579]|[14579]0|\d0{3,5})[.]) \1-kel # cardinal ([{\(\[]?(0|.*[^0]0{6,8}|.*[^0]0{12,14}|[ahkoquAHKOQU][.]?)[}\)\]]?) \1-val (.*[14][}\)\]]?) \1-gyel (.*(2|[bcdegijptvwzBCDEGIJPTVWZ][.]?)[}\)\]]?) \1-vel (.*3[}\)\]]?) \1-mal (.*[57][}\)\]]?) \1-tel (.*6[}\)\]]?) \1-tal ((.*8|.*30)[}\)\]]?) \1-cal (.*9[}\)\]]?) \1-cel (.*10[}\)\]]?) \1-zel (.*20[}\)\]]?) \1-szal (.*[4579]0[}\)\]]?) \1-nel (.*([68]0|[yY][.]?)[}\)\]]?) \1-nal (.*[^0]00[}\)\]]?) \1-zal (.*[^0]0{3,5}[}\)\]]?) \1-rel ((.*[^0]0{9,11}|.*[^0]0{15,17})[}\)\]]?) \1-dal (.*([flmnrsFLMNRS])[.]?[}\)\]]?) \1-\2el (.*[xX][.]?[}\)\]]?) \1-szel == -vá == ([{\(\[]?(\d+|[a-zA-Z])[}\)\]]?) $(-vá $(-val \1)) (.*)al \1á (.*)el \1é == (-a|-ad|-ai|-án|-áig|-ban?|-ból|-hoz|-i|-nak|-nál|-on|-ra|-ról|-as|-szoros|-at|-á?tól|-ul) == # 1-be, 2-nek, 2.-nak, 12.-nek, 4-et etc., b)-ben, c)-ből, d)-hez, n-et etc. # add affix after conversion to the alternative form ([{\(\[]?(2|.+2[.]?|.*[14579][.]?|.*[14579]0[.]?|.*[^0]0{3,5}[.]?|[bcdefgijlmnprstvwxzBCDEFGIJLMNPRSTVWXZ][.]?)[}\)\]]?) \2$(-on \1) # otherwise: 0-ba, 3-at, 6-nál etc., a)-ban, h)-ból, k-hoz, y-ról etc. ([{\(\[]?(.*[0-9]+[.]?|[ahkoquyAHKOQUY][.]?)[}\)\]]?) \2\1 # conversion to the alternative form: -ban -> -ben etc. -szoros -szeres -(.*)[ao](.*) -\2e\3 -([brt])ól -\2ől -ától -étől -(.*)[á](.*) -\2é\3 -ul -ül (-ig?) \2 == help == "" $(1)|, $(2)|, $(3)\n$(\0 ordinal)$(\0 ordinal-number)year: $(year 2001), $(year 2002)|, $(year 2003)\nformal: $(formal 100), $(formal 200), $(formal 1000)\ntext: $(text 1), $(text 12000), $(text 10000000000)\ncurrency \(for example, HUF\): $(HUF 2,5)\nformal HUF: $(formal HUF 102,5)\nSuffixation of numbers and letters: -a, -ában, -án, -áig, -ától, -ba, -ban, -ból, -d, -dik, -hoz,\n -nak, -nál, -n, -ra, -ról, -s, -szor, -szoros, -t, -tól, -ul, -vá, -val,\n for example: -szor 15 -> $(-szor 15)\narticle: $(article 5)\narticle cardinal: $(article cardinal 100)\narticle cardinal formal: $(article cardinal formal 100)\narticle -ban: $(article -ban a\))\narticle -ai: $(article -ai 1)\narticle ordinal -ai: $(article ordinal -ai 1)|\ncanonical-name: -szor -> $(canonical-name -szor) "(ordinal(-number)?|USD)" \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 nol 1 satu 2 dua 3 tiga 4 empat 5 lima 6 enam 7 tujuh 8 delapan 9 sembilan 10 sepuluh 11 sebelas 1(\d) $1 belas (\d)(\d) $1 puluh[ $2] 1(\d\d) seratus[ $1] (\d)(\d\d) $1 ratus[ $2] 1(\d{3}) seribu[ $1] (\d{1,3})(\d{3}) $1 ribu[ $2] # sejuta or setu juta etc. (\d{1,3})(\d{6}) $1 juta[ $2] (\d{1,3})(\d{9}) $1 miliar[ $2] (\d{1,3})(\d{12}) $1 triliun[ $2] (\d{1,3})(\d{15}) $1 kuadriliun[ $2] (\d{1,3})(\d{18}) $1 kuantiliun[ $2] (\d{1,3})(\d{21}) $1 sextiliun[ $2] (\d{1,3})(\d{24}) $1 septiliun[ $2] # negative numbers [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| koma "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit u:(.*),(.*) \1 s:(.*),(.*) \2 AUD:(.) $(\1: dollar Australia, sen) BGN:(.) $(\1: lev, leva, stotinka, stotinki) BWP:(.) $(\1: pula, pula, thebe, thebe) CAD:(.) $(\1: dollar Kanada, sen) CHF:(.) $(\1: franc Swiss, sen) CNY:(.) $(\1: yuan, fen) CZK:(.) $(\1: koruna Czech, koruna Czech, halér, halére) EEK:(.) $(\1: kroon, kroonid, sen) EUR:(.) $(\1: euro, sen) GBP:(.) $(\1: pound sterling, penny) GHS:(.) $(\1: cedi Ghana, pesewas) GMD:(.) $(\1: dalasi, bututs) HKD:(.) $(\1: dollar Hongkong, sen) IDR:(.) $(\1: rupiah, sen) INR:(.) $(\1: rupee India, paisa) JMD:(.) $(\1: dollar Jamaika, sen) JPY:(.) $(\1: yen, sen) KRW:(.) $(\1: won, chon) KES:(.) $(\1: shilling Kenya, sen) LRD:(.) $(\1: dollar Liberia, sen) LSL:(.) $(\1: loti, sente) LTL:(.) $(\1: litas, sen) LVL:(.) $(\1: lats, sen) MGA:(.) $(\1: ariary, iraimbilanja) MUR:(.) $(\1: rupee Mauritius, sen) MXN:(.) $(\1: peso Meksiko, centavo) MWK:(.) $(\1: kwacha Malawi, tambala) NAD:(.) $(\1: dollar Namibia, sen) NGN:(.) $(\1: naira, kobo) NZD:(.) $(\1: dollar New Zealand, sen) PGK:(.) $(\1: kina, toea) PHP:(.) $(\1: peso Filipina, centavo) PKR:(.) $(\1: rupee Pakistan, paisa) PLN:(.) $(\1: zloty, grosz) RON:(.) $(\1: leu Romania, ban) RSD:(.) $(\1: dinar Serbia, para) RUB:(.) $(\1: ruble Russia, kopek) RWF:(.) $(\1: franc Rwanda, centime) SGD:(.) $(\1: dollar Singapura, sen) SLL:(.) $(\1: leone, sen) SZL:(.) $(\1: lilangeni, sen) THB:(.) $(\1: baht, satang) TRY:(.) $(\1: lira Turki, kurus) TTD:(.) $(\1: dollar Trinidad dan Tobago, sen) TZS:(.) $(\1: shilling Tanzania,sen) UAH:(.) $(\1: hryvnia, kopiyka) UGX:(.) $(\1: shilling Uganda, sen) USD:(.) $(\1: dolar Amerika, sen) ZAR:(.) $(\1: rand Afrika Selatan, sen) ZMK:(.) $(\1: kwacha Zambia, ngwee) ZWL:(.) $(\1: dollar Zimbabwe, sen) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 yiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 dan $(\30)$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 dan $3$(\2:s) == ordinal == 1 pertama (\d+) $(ordinal ke$1) "kesatu (.*)" kese\1 (.*) \1 == ordinal-number == 1 1 (\d+) ke-\1 == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 núll 1 einn 2 tveir 3 þrír 4 fjórir 5 fimm 6 sex 7 sjö 8 átta 9 níu 10 tíu 11 ellefu 12 tólf 13 þrettán 14 fjórtán 1([56]) $1tán 17 sautján 18 átján 19 nítján 2(\d) tuttugu[ og $1] 3(\d) þrjátíu[ og $1] 4(\d) fjörutíu[ og $1] (\d)(\d) $1tíu[ og $2] 1(\d\d) hundrað[ og $1] (\d)(\d\d) [$(cardinal-neuter $1) ]hundrað[ og $2] 1(\d{3}) þúsund[ og $1] (\d{1,3})(\d{3}) [$(cardinal-neuter $1) ]þúsund[ og $2] 1(\d{6}) ein milljón[ $1] (\d{1,3})(\d{6}) [$(cardinal-feminine $1) ]milljónir[ og $2] 1(\d{9}) einn miljarður[ $1] (\d{1,33})(\d{9}) [$1 ]miljarðar[ $2] # negative number [-−](\d+) neikvæð |$1 # decimals 0[.,] kommu ([-−]?\d+)[.,] $1| kommu ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural "us, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\2 \1) \3 "up, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\2 \1) \4 "ss, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\5 \1) \6 "sp, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\5 \1) \7 DKK:(\D+,.*) $(\1: cardinal, dönsk króna, dönsk króna, cardinal, aura, aura) EUR:(\D+,.*) $(\1: cardinal, evra, evra, cardinal-neuter, sent, sent) ISK:(\D+,.*) $(\1: cardinal, króna, krónur, cardinal, aura, aura) GBP:(\D+,.*) $(\1: cardinal-neuter, breskt pund, breskt pund, cardinal, penní, penní) NOK:(\D+,.*) $(\1: cardinal, norsk króna, norsk krónur, cardinal, aura, aura) SEK:(\D+,.*) $(\1: cardinal, sænsk króna, sænsk krónur, cardinal, aura, aura) USD:(\D+,.*) $(\1: cardinal, Bandaríkjadalur, Bandaríkjadalir, cardinal-neuter, sent, sent) "([A-Z]{3}) ([-−]?1)([.,]00?)?"$(\1:us, \2) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(\1:up, \2) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 $(\2:ss, 1) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\2:sp, \30) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $(\2:sp, \3) == cardinal(-masculine)? == (\d+) $2 == cardinal-feminine == (\d+) $(cardinal-feminine $1) (.*)einn \1ein (.*)tveir \1tvær (.*)þrír \1þrjár (.*)fjórir \1fjórar (.*) \1 == cardinal-neuter == (\d+) $(cardinal-neuter $1) (.*)einn \1eitt (.*)tveir \1tvö (.*)þrír \1þrjú (.*)fjórir \1fjögur (.*) \1 == ordinal(-masculine)? == 0 1 fyrsti 2 annar 3 þriðji 4 fjórði 5 fimmti 6 sjötti 7 sjöundi 8 áttundi 9 níundi 10 tíundi (1\d) $2di 2(\d) tuttugasti[ og $(ordinal \2)] 3(\d) þrítugasti[ og $(ordinal \2)] 4(\d) fertugasti[ og $(ordinal \2)] 8(\d) áttugasti[ og $(ordinal \2)] (\d)(\d) $2tugasti[ og $(ordinal \3)] 1(\d\d) hundraðasti[ og $(ordinal \2)] (\d)(\d\d) [$(cardinal-neuter \2)]hundraðasti[ og $(ordinal \3)] 1(\d{3}) þúsundasti[ og $(ordinal \2)] (\d{1,3})(\d{3}) [$(cardinal-neuter \2)]hundraðasti[ og $(ordinal \3)] (.*) \1 == ordinal-feminine == (.*)annar(.*) $(ordinal-feminine \1önnur\2) == ordinal-neuter == (.*)annar(.*) $(ordinal-feminine \1annað\2) == ordinal(-feminine|-neuter)? == (\d+) $(ordinal-feminine |$(ordinal \2)) (.*)i\b(.*) $(ordinal-feminine \2a\3) (.*) \2 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help cardinal-neuter)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-neuter)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 zero 1 uno 2 due ^3$ tre 3$ tré 3 tre 4 quattro 5 cinque 6 sei 7 sette 8 otto 9 nove 10 dieci 11 undici 12 dodici 13 tredici 14 quattordici 15 quindici 16 sedici 17 diciassette 18 diciotto 19 diciannove 2([18]) vent$1 2(\d) venti$1 3([18]) trent$1 3(\d) trenta$1 4([18]) quarant$1 4(\d) quaranta$1 5([18]) cinquant$1 5(\d) cinquanta$1 6([18]) sessant$1 6(\d) sessanta$1 7([18]) settant$1 7(\d) settanta$1 8([18]) ottant$1 8(\d) ottanta$1 9([18]) novant$1 9(\d) novanta$1 1(\d\d) cento$1 (\d)(\d\d) $1cento$2 1(\d{3}) mille$1 (\d{1,2})(\d{3}) $1mila$2 (\d{3})(\d{3}) $1mila[ $2] 1(\d{6}) un milione[ $1] (\d{1,3})(\d{6}) $1 milioni[ $2] 1(\d{9}) un miliardo[ $1] (\d{1,3})(\d{9}) $1 miliardi[ $2] 1(\d{12}) un bilione[ $1] (\d{1,3})(\d{12}) $1 bilioni[ $2] 1(\d{15}) un biliardo[ $1] (\d{1,3})(\d{15}) $1 biliardi[ $2] 1(\d{18}) un trilione[ $1] (\d{1,3})(\d{18}) $1 trilioni[ $2] 1(\d{21}) un triliardo[ $1] (\d{1,3})(\d{21}) $1 triliardi[ $2] # negative numbers [-−](\d+) meno |$1 # decimals ([-−]?\d+)[.,] $1| virgola ([-−]?\d+[.,])([^0]\d) $1| |$2 ([-−]?\d+[.,])(\d)(\d)(\d) |$1 |$2| |$3| |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currencies # unit/subunit u:([^,]*),([^,]*),([^,]*) \1 s:([^,]*),([^,]*),([^,]*) \2 p:([^,]*),([^,]*),([^,]*) \3 CHF:(.) $(\1: franco svizzero, centesimo, centesimi) CNY:(.) $(\1: yuan renminbi, fen, fen) EUR:(.) $(\1: euro, centesimo, centesimi) GBP:(.) $(\1: lira sterlina, penny, pence) JPY:(.) $(\1: yen, sen, sen) USD:(.) $(\1: dollaro USA, cent, cent) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 uno$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:p) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:p) == cardinal-feminine == 1 una == cardinal-masculine == 1 un == cardinal-(feminine|masculine) == (.*) $(\1 $2) == feminine == (.*)uno \1una == masculine == (.*)uno \1un == (feminine|masculine) == (.*) \2 == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine |$1) un[ao] \1prima (.*)un[ao] \1unesima due seconda (.*)due \1duesima (.*)tre \1terza (.*)quattro \1quarta (.*)cinque \1quinta (.*)sei \1sesta (.*)sette \1settesima (.*)ootto \1ottesima (.*)otto \1ottesima (.*)nove \1novesima (.*)dieci \1decima (.*tr)é \1eesima (.*sei) \1esima "(.*)[^ ][ ]*" \1esima == ordinal(-masculine)? == ([-−]?\d+) $(ordinal-masculine $(ordinal-feminine \2)) (.*)a \2o == (ordinal)-number(-feminine|-masculine)? == ([-−]?\d+) \3$(ordinal-number $(\1\2 \3)) .*a ª .*o º == help == "" $(1), $(2), |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number-feminine)$(help ordinal-number-masculine) (.*) \1: $(\1 1), $(\1 2), |$(\1 3)|\n
^0 零 1 一 2 二 3 三 4 四 5 五 6 六 7 七 8 八 9 九 1(\d) 十$1 (\d)(\d) $1十$2 1(\d\d) 百$1 (\d)(\d\d) $1百$2 1(\d\d\d) 千$1 (\d)(\d\d\d) $1千$2 (\d{1,4})(\d{4}) $1万$2 (\d{1,4})(\d{8}) $1億$2 (\d{1,4})(\d{12}) $1兆$2 (\d{1,4})(\d{16}) $1京$2 (\d{1,4})(\d{20}) $1垓$2 (\d{1,4})(\d{24}) $1秭$2 (\d{1,4})(\d{28}) $1穣$2 (\d{1,4})(\d{32}) $1溝$2 (\d{1,4})(\d{36}) $1澗$2 (\d{1,4})(\d{40}) $1正$2 (\d{1,4})(\d{44}) $1載$2 # negative numbers? [-−](\d+) 負|$1 # decimals? "([-−]?\d+)[.,]" "$1・" "([-−]?\d+[.,]\d*)(\d)" $1||$2 # currency # unit/subunit singular/plural JPY 円 "([A-Z]{3}) ([-−]?\d+([.,]\d+)?)" $2$1 # formal numbers (大字) for legal and financial documents == formal == ^0 零 1 壱 2 弐 3 参 4 四 5 五 6 六 7 七 8 八 9 九 1(\d) 拾$(formal \1) (\d)(\d) $(formal \1)拾$(formal \2) 1(\d\d) 百$(formal \1) (\d)(\d\d) $(formal \1)百$(formal \2) 1(\d\d\d) 千$(formal \1) (\d)(\d\d\d) $(formal \1)千$(formal \2) (\d{1,4})(\d{4}) $(formal \1)万$(formal \2) (\d{1,4})(\d{8}) $(formal \1)億$(formal \2) (\d{1,4})(\d{12}) $(formal \1)兆$(formal \2) (\d{1,4})(\d{16}) $(formal \1)京$(formal \2) (\d{1,4})(\d{20}) $(formal \1)垓$(formal \2) (\d{1,4})(\d{24}) $(formal \1)秭$(formal \2) (\d{1,4})(\d{28}) $(formal \1)穣$(formal \2) (\d{1,4})(\d{32}) $(formal \1)溝$(formal \2) (\d{1,4})(\d{36}) $(formal \1)澗$(formal \2) (\d{1,4})(\d{40}) $(formal \1)正$(formal \2) (\d{1,4})(\d{44}) $(formal \1)載$(formal \2) # negative numbers? [-−](\d+) 負|$(formal \1) # decimals "([-−]?\d+)[.,]" "$(formal \1)・" "([-−]?\d+[.,]\d*)(\d)" $(formal \1)||$(formal \2) # currency # unit/subunit singular/plural JPY 円 "([A-Z]{3}) ([-−]?\d+([.,]\d+)?)" $(formal \2)$(formal \1) == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help formal) (formal) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 령 # [:ko-KP:] ^0 영 1 일 2 이 3 삼 4 사 5 오 6 륙 # [:ko-KP:] 6 육 7 칠 8 팔 9 구 1(\d) 십$1 (\d)(\d) $1십$2 1(\d\d) 백$1 (\d)(\d\d) $1백$2 1(\d\d\d) 천$1 (\d)(\d\d\d) $1천$2 (\d{1,4})(\d{4}) $1만$2 (\d{1,4})(\d{8}) $1억$2 (\d{1,4})(\d{12}) $1조$2 (\d{1,4})(\d{16}) $1경$2 (\d{1,4})(\d{20}) $1해$2 (\d{1,4})(\d{24}) $1자$2 (\d{1,4})(\d{28}) $1양$2 (\d{1,4})(\d{32}) $1구$2 (\d{1,4})(\d{36}) $1간$2 (\d{1,4})(\d{40}) $1정$2 (\d{1,4})(\d{44}) $1재$2 (\d{1,4})(\d{52}) $1극$2 # negative numbers [-−](\d+) 음수|$1 # decimals? "([-−]?\d+)[.]" "$1|점" "([-−]?\d+[.]\d*)(\d)" $1||$2 # currency # unit/subunit us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 AUD:(\D+) $(\1: 호주달러, 호주달러, 센트, 센트) EUR:(\D+) $(\1: 유로, 유로, 센트, 센트) GBP:(\D+) $(\1: 파운드, 파운드, 페니, 펜스) CNY:(\D+) $(\1:위안, 위안, 펀, 펀) TWD:(\D+) $(\1:대만달러, 대만달러, 펀, 펀) HKD:(\D+) $(\1:홍콩달러, 홍콩달러, 센트, 센트) JPY:(\D+) $(\1:엔, 엔, 센, 센) KPW:(\D+) $(\1:원, 원 전, 전) KRW:(\D+) $(\1:원, 원, 전, 전) SGD:(\D+) $(\1: 싱가포르달러, 싱가포르달러, 센트, 센트) THB:(\D+) $(\1: 바트, 바트, 사탕, 사탕) USD:(\D+) $(\1:달러, 달러, 센트, 센트) "(JPY [-−]?\d+)[.](\d\d)0" $1 "(JPY [-−]?\d+[.]\d\d)(\d)" $1 $2 린 "([A-Z]{3}) ([-−]?1)([.]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.](\d)0?" $1 $2 자오 "(CNY [-−]?\d+[.]\d)(\d)" $1 $2 펀 "(TWD [-−]?\d+)[.](\d)0?" $1 $2 자오 "(TWD [-−]?\d+[.]\d)(\d)" $1 $2 펀 "(([A-Z]{3}) [-−]?\d+)[.](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.](\d\d)" $1 |$3$(\2:sp) == money == "(JPY [-−]?\d+)[.](\d\d)0" $1 "(JPY [-−]?\d+[.]\d\d)(\d)" $1 $2 린 "([A-Z]{3}) ([-−]?1)([.]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.](\d)0?" $1 $2 자오 "(CNY [-−]?\d+[.]\d)(\d)" $1 $2 펀 "(TWD [-−]?\d+)[.](\d)0?" $1 $2 자오 "(TWD [-−]?\d+[.]\d)(\d)" $1 $2 펀 "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) ([-−]?\d+))[.](01)" $3 and 1/100$(\2:us) "(([A-Z]{3}) ([-−]?\d+))[.](\d)" $3 and \40/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.](\d\d)" $3 and \4/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.](\d\d\d)" $3 and \4/1000$(\2:up)
^0 null 1$ eent 1 een 2 zwee 3 dräi 4 véier 5 fënnef 6 sechs 7 siwen 8 aacht 9 néng 10 zéng 11 eelef 12 zwielef 15 fofzéng 16 siechzéng 17 siwwenzéng 18 uechzéng 19 nonzéng 1(\d) $1zéng 20 zwanzeg 2(\d) $1anzwanzeg 30 drësseg 3(\d) $1andrësseg 4(\d) $1avéierzeg 50 foffzeg 5(\d) $1afoffzeg 60 siechzeg 6(\d) $1asiechzeg 70 siwwenzeg 7(\d) $1asiwwenzeg 80 achtzeg 8(\d) $1anachtzeg 90 nonzeg 9(\d) $1annonzeg (\d)0 $1zeg (\d)(\d) $2an$1zeg 1(\d\d) honnert$1 (\d)(\d\d) $1honnert$2 1(\d{3}) dausend$1 (\d{1,3})(\d{3}) $1dausend$2 1(\d{6}) eng Millioun[ $1] (\d{1,3})(\d{6}) $1 Milliounen[ $2] 1(\d{9}) eng Milliard[ $1] (\d{1,3})(\d{9}) $1 Milliarden[ $2] 1(\d{12}) eng Billioun[ $1] (\d{1,3})(\d{12}) $1 Billiounen[ $2] 1(\d{15}) eng Billiard[ $1] (\d{1,3})(\d{15}) $1 Billiarden[ $2] 1(\d{18}) eng Trillioun[ $1] (\d{1,3})(\d{18}) $1 Trilliounen[ $2] 1(\d{21}) eng Trilliard[ $1] (\d{1,3})(\d{21}) $1 Trilliarden[ $2] # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| Komma "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: Schwäizer Frang, Schwäizer Frang, Rappen, Rappen) CNY:(\D+) $(\1: Yuan, Yuan, Fen, Fen) EUR:(\D+) $(\1: Euro, Euro, Cent, Cent) GBP:(\D+) $(\1: Pond Sterling, Pond Sterling, Penny, Pence) USD:(\D+) $(\1: US-Dollar, US-Dollar, Cent, Cents) "JPY ([-−]?\d+([.,]\d+)?)" $1 Yen "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,]10?" $1 $2 Jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 Jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 Fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 Fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 an $(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 an $(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 an $3$(\2:sp) == ordinal == ([-−]?[0245679]) $1t ([-−]?\d*0[245679]) $1t ([-−]?\d*1\d) $1t ([-−]?\d+) $(ordinal $1) (.*)eent \1éischt (.*)dräi \1drëtt (.*)aacht \1aacht "(.*)eine Milli(on|ard)e?" \1einmilli\2st "(.*)eine Billi(on|ard)e?" \1einbilli\2st "(.*)eine Trilli(on|ard)e?" \1eintrilli\2st "(.*) Milli(on|ard)en" \1milli\2st "(.*) Billi(on|ard)en" \1billi\2st "(.*) Trilli(on|ard)en" \1trilli\2st (.*) \1st == ordinal-number == (\d+) \1. == help == "" |$(1)|, $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: |$(\1 1)|, $(\1 2), $(\1 3)\n
^0 zeero :1 mu :2 biri :3 satu :4 na :5 taano :6 kaaga :7 sanvu :8 naana :9 enda :10 kumi 1 emu 2 b$(:2) 3 s$(:3) 4 nnya 5 t$(:5) 6 mu$(:6) 7 mu$(:7) 8 mu$(:8) 9 mw$(:9) 1(\d) k$(:10) [na $1] ([2-5])(\d) ama$(:10) a$(:\1) [mu $2] ([67])(\d) n$(:\1) [mu $2] 8(\d) ki$(:8) [mu $1] 9(\d) ky$(:9) [mu $1] 1(\d\d) ki$(:10) [mu $1] ([2-5])(\d\d) bi$(:10) bi$(:\1) [mu $2] ([6-8])(\d\d) lu$(:\1) [mu $2] 9(\d\d) lw$(:9) [mu $1] 1(\d\d\d) lu$(:10) [mu $1] ([2-5])(\d\d\d) n$(:10) $1 [mu $2] ([6-8])(\d\d\d) ka$(:\1) [mu $2] 9(\d\d\d) k$(:9) [mu $1] 1(\d{4}) mutwalo [gu$(:1) mu $1] ([2-5])(\d{4}) mitwalo e$(:\1) [mu $2] ([6-9])(\d{4}) mitwalo $1 [mu $2] (\d\d)(\d{4}) mitwalo $1 [mu $2] 1(\d{6}) kakadde [ka$(:1) ne $1] 9(\d{6}) bukadde bw$(:9) [ne $1] (\d)(\d{6}) bukadde bu$(:\1) [ne $2] (\d{2,6})(\d{6}) bukadde $1 [ne $2] 1(\d{12}) kawumbi [ka$(:1) ne $1] 9(\d{12}) buwumbi bw$(:9) [ne $1] (\d)(\d{12}) buwumbi bu$(:\1) [ne $2] (\d{2,6})(\d{12}) buwumbi $1 [ne $2] 1(\d{18}) kafukunya [ka$(:1) ne $1] 9(\d{18}) bufukunya bw$(:9) [ne $1] (\d)(\d{18}) bufukunya bu$(:\1) [ne $2] (\d{2,6})(\d{18}) bufukunya $1 [ne $2] 1(\d{24}) kasedde [ka$(:1) ne $1] 9(\d{24}) busedde bw$(:9) [ne $1] (\d)(\d{24}) busedde bu$(:\1) [ne $2] (\d{2,6})(\d{24}) busedde $1 [ne $2] # eŋŋaanyi [-−](\d+) eŋŋaanyi |$1 # decimals 0[.,] katonnyeze ([-−]?\d+)[.,] $1| katonnyeze ([-−]?\d+[.,]\d*)(\d) $1| |$2 # unit/subunit u:([^,]*),([^,]*) \1 #s:([^,]*),([^,]*) \2 GBP:(\D) $(\1: pound za U.K) KES:(\D) $(\1: ssiringi za Kenya) UGX:(\D) $(\1: ssiringi za Uganda) USD:(\D) $(\1: U.S. doola) TZS:(\D) $(\1: ssiringi za Tanzania) "([A-Z]{3}) (.+)" $(\1:u) |$2 == ordinal == 1 esooka ([2-5]) eyoku$(:\1) ([6-9]) eyo$1 (1\d) eye$1 (\d+) eya $1 [-−](\d+) eŋŋaanyi $(ordinal \1) == ordinal-number == (\d+) ey\1 == year == (\d+) mwaka $1
^0 nulis 1 vienas 2 du 3 trys 4 keturi 5 penki 6 šeši 7 septyni 8 aštuoni 9 devyni 10 dešimt 11 vienuolika 12 dvylika 13 trylika 14 keturiolika 15 penkiolika 16 šešiolika 17 septyniolika 18 aštuoniolika 19 devyniolika 2(\d) dvidešimt[ $1] 3(\d) trisdešimt[ $1] ([4-9])(\d) $1|asdešimt[ $2] 1(\d\d) vienas šimtas[ $1] ([2-9])(\d\d) $1 šimtai[ $2] 1(\d{3}) vienas tūkstantis[ $1] (\d?1\d|\d?\d?0)(\d{3}) $1 tūkstančių[ $2] (\d?\d1)(\d{3}) $1 tūkstantis[ $2] (\d{1,3})(\d{3}) $1 tūkstančiai[ $2] (\d?1\d|\d?\d?0)(\d{6}) $1 milijonų[ $2] (\d?\d?1)(\d{6}) $1 milijonas[ $2] (\d{1,3})(\d{6}) $1 milijonai[ $2] (\d?1\d|\d?\d?0)(\d{9}) $1 milijardų[ $2] (\d?\d?1)(\d{9}) $1 milijardas[ $2] (\d{1,3})(\d{9}) $1 milijardai[ $2] (\d?1\d|\d?\d?0)(\d{12}) $1 trilijonų[ $2] (\d?\d?1)(\d{12}) $1 trilijonas[ $2] (\d{1,3})(\d{12}) $1 trilijonai[ $2] (\d?1\d|\d?\d?0)(\d{15}) $1 kvadrilijonų[ $2] (\d?\d?1)(\d{15}) $1 kvadrilijonas[ $2] (\d{1,3})(\d{15}) $1 kvadrilijonai[ $2] (\d?1\d|\d?\d?0)(\d{18}) $1 kvintilijonų[ $2] (\d?\d?1)(\d{18}) $1 kvintilijonas[ $2] (\d{1,3})(\d{18}) $1 kvintilijonai[ $2] # negative numbers [-−](\d+) minus |$1 # decimals # before delimiter ([-−]?(1|\d*[02-9]1))[.,] $1| sveikas ([-−]?\d*[2-9])[.,] $1| sveiki (0|[-−]?\d*(1[1-9]|[1-9]0))[.,] $1| sveikų # atfer delimiter "([-−]?\d+[.,])(1)" $1| ir |$(f:$2) dešimtoji "([-−]?\d+[.,])([2-9])" $1| ir |$(f:$2) dešimtosios "([-−]?\d+[.,])([02-9]1)" $1| ir |$(f:$2) šimtoji "([-−]?\d+[.,])(1[1-9]|[1-9]0)" $1| ir |$(f:$2) šimtųjų "([-−]?\d+[.,])([02-9][2-9])" $1| ir |$(f:$2) šimtosios "([-−]?\d+[.,])(\d[02-9]1)" $1| ir |$(f:$2) tūkstantoji "([-−]?\d+[.,])(\d1[1-9]|[1-9]0)" $1| ir |$(f:$2) tūkstantųjų "([-−]?\d+[.,])(\d[02-9][2-9])" $1| ir |$(f:$2) tūkstantosios # female conversion f:(.*)as \1a f:(.*)du \1dvi f:(.*)i \1ios f:(.*) \1 # currency # unit/subunit singular/plural_a/plural_b us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 upa:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 upb:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 spa:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 spb:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 AUD:(\D+) $(\1: Australijos doleris, Australijos dolerių, Australijos doleriai, centas, centų, centai) BGN:(\D+) $(\1: levas, levų, levai, stotinka, stotinkų, stotinkos) CAD:(\D+) $(\1: Kanados doleris, Kanados dolerių, Kanados doleriai, centas, centų, centai) CHF:(\D+) $(\1: Šveicarijos frankas, Šveicarijos frankų, Šveicarijos frankai, santimas, santimų, santimai) CZK:(\D+) $(\1: Čekijos krona, Čekijos kronų, Čekijos kronos, heleris, helerių, heleriai) EEK:(\D+) $(\1: Estijos krona, Estijos kronų, Estijos kronos, sentas, sentų, sentai) EUR:(\D+) $(\1: euras, eurų, eurai, euro centas, euro centų, euro centai) GBP:(\D+) $(\1: svaras sterlingų, svarų sterlingų, svarai sterlingų, pensas, pensų, pensai) GHS:(\D+) $(\1: sedis, sedžių, sedžiai, peseva, pesevų, pesevos) HKD:(\D+) $(\1: Honkongo doleris, Honkongo dolerių, Honkongo doleriai, centas, centų, centai) HRK:(\D+) $(\1: kuna, kunų, kunos, lipa, lipų, lipos) HUF:(\D+) $(\1: forintas, forintų, forintai, fileris, filerių, fileriai) INR:(\D+) $(\1: Indijos rupija, Indijos rupijų, Indijos rupijos, paisa, paisų, paisos) JMD:(\D+) $(\1: Jamaikos doleris, Jamaikos dolerių, Jamaikos doleriai, centas, centų, centai) KES:(\D+) $(\1: Kenijos šilingas, Kenijos šilingų, Kenijos šilingai, centas, centų, centai) LRD:(\D+) $(\1: Liberijos doleris, Liberijos dolerių, Liberijos doleriai, centas, centų, centai) LTL:(\D+) $(\1: litas, litų, litai, centas, centų, centai) LVL:(\D+) $(\1: lats, lati, santims, santimi) MUR:(\D+) $(\1: Mauricijaus rupija, Mauricijaus rupijų, Mauricijaus rupijos, centas, centų, centai) MXN:(\D+) $(\1: Meksikos pesas, Meksikos pesų, Meksikos pesai, sentavas, sentavų, sentavai) MWK:(\D+) $(\1: Malavio kvača, Malavio kvačų, Malavio kvačos, tambala, tambalų, tambalos) NAD:(\D+) $(\1: Namibijos doleris, Namibijos dolerių, Namibijos doleriai, centas, centų, centai) NGN:(\D+) $(\1: naira, nairų, nairos, koba, kobų, kobos) NOK:(\D+) $(\1: Norvegijos krona, Norvegijos kronų, Norvegijos kronos, erė, erių, erės) NZD:(\D+) $(\1: Naujosios Zelandijos doleris, Naujosios Zelandijos dolerių, Naujosios Zelandijos doleriai, centas, centų, centai) PGK:(\D+) $(\1: kina, kinų, kinos, toja, tojų, tojos) PHP:(\D+) $(\1: Filipinų pesas, Filipinų pesų, Filipinų pesai, sentimas, sentimų, sentimai) PKR:(\D+) $(\1: Pakistano rupija, Pakistano rupijų, Pakistano rupijos, paisa, paisų, paisos) PLN:(\D+) $(\1: zlotas, zlotų, zlotai, grašis, grašių, grašiai) RON:(\D+) $(\1: Rumunijos lėja, Rumunijos lėjų, Rumunijos lėjos, banas, banų, banai) RSD:(\D+) $(\1: Serbijos dinaras, Serbijos dinarų, Serbijos dinarai, paras, parų, parai) RUB:(\D+) $(\1: Rusijos rublis, Rusijos rublių, Rusijos rubliai, kapeika, kapeikų, kapeikos) RWF:(\D+) $(\1: Ruandos frankas, Ruandos frankų, Ruandos frankai, sentimas, sentimų, sentimai) SDG:(\D+) $(\1: Sudano svaras, Sudano svarų, Sudano svarai, piastras, piastrų, piastrai) SEK:(\D+) $(\1: Švedijos krona, Švedijos kronų, Švedijos kronos, erė, erių, erės) SGD:(\D+) $(\1: Singapūro doleris, Singapūro dolerių, Singapūro doleriai, centas, centų, centai) SLL:(\D+) $(\1: leonė, leonių, leonės, centas, centų, centai) THB:(\D+) $(\1: Tailando batas, Tailando batų, Tailando batai, satangas, satangų, satangai) TRY:(\D+) $(\1: Turkijos lira, Turkijos lirų, Turkijos liros, kurušas, kurušų, kurušai) TTD:(\D+) $(\1: Trinidado ir Tobago doleris, Trinidado ir Tobago dolerių, Trinidado ir Tobago doleriai, centas, centų, centai) TZS:(\D+) $(\1: Tanzanijos šilingas, Tanzanijos šilingų, Tanzanijos šilingai, centas, centų, centai) UAH:(\D+) $(\1: grivina, grivinų, grivinos, kapeika, kapeikų, kapeikos) UGX:(\D+) $(\1: Ugandos šilingas, Ugandos šilingų, Ugandos šilingai, centas, centų, centai) USD:(\D+) $(\1: JAV doleris, JAV dolerių, JAV doleriai, centas, centų, centai) ZAR:(\D+) $(\1: Pietų Afrikos randas, Pietų Afrikos randų, Pietų Afrikos randai, centas, centų, centai) ZMK:(\D+) $(\1: Zambijos kvača, Zambijos kvačų, Zambijos kvačos, ngvi, ngvių, ngvės) ZWL:(\D+) $(\1: Zimbabvės doleris, Zimbabvės dolerių, Zimbabvės doleriai, centas, centų, centai) # female gender # before delimiter "(CZK|EEK|HRK|INR|MUR|MWK|NGN|NOK|PGK|PKR|RON|SEK|SLL|TRY|UAH|ZMK) ([-−]?(1|\d*[02-9]1))([.,]00?)?" $(f:$2)|$(\1:us) # 1| *01| *21 ... "(CZK|EEK|HRK|INR|MUR|MWK|NGN|NOK|PGK|PKR|RON|SEK|SLL|TRY|UAH|ZMK) ([-−]?(0|\d*(1[1-9]|[01-9]0)))([.,]00?)?" $2|$(\1:upa) # 0 | *11| *19| *10| *30 ... "(CZK|EEK|HRK|INR|MUR|MWK|NGN|NOK|PGK|PKR|RON|SEK|SLL|TRY|UAH|ZMK) ([-−]?\d*[2-9])([.,]00?)?" $(f:$2)|$(\1:upb) # *2| *8 ... # atfer delimiter "((BGN|GHS|HRK|INR|MWK|NGN|NOK|PGK|PKR|SEK|RUB|UAH|ZMK) [-−]?\d+)[.,](0+)" $1| # 0, 00 "((BGN|GHS|HRK|INR|MWK|NGN|NOK|PGK|PKR|SEK|RUB|UAH|ZMK) [-−]?\d+)[.,]([02-9]1)" $1| ir |$(f:$3)|$(\2:ss) # 1, 21, 31, ..., 91 "((BGN|GHS|HRK|INR|MWK|NGN|NOK|PGK|PKR|SEK|RUB|UAH|ZMK) [-−]?\d+)[.,](\d)" $1| ir |$(\30)$(\2:spa) # *,x conversion to *,x0 "((BGN|GHS|HRK|INR|MWK|NGN|NOK|PGK|PKR|SEK|RUB|UAH|ZMK) [-−]?\d+)[.,](1[0-9]|[2-9]0)" $1| ir |$3|$(\2:spa) # 10-19, 20, 30, ..., 90 "((BGN|GHS|HRK|INR|MWK|NGN|NOK|PGK|PKR|SEK|RUB|UAH|ZMK) [-−]?\d+)[.,](\d\d)" $1| ir |$(f:$3)$(\2:spb) # all the rest # male gender (all except female gender filter matches) # before delimiter "([A-Z]{3}) ([-−]?(1|\d*[02-9]1))([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?0|\d*(1[1-9]|[01-9]0))([.,]00?)?" $2|$(\1:upa) "([A-Z]{3}) ([-−]?\d*[2-9])([.,]00?)?" $2|$(\1:upb) # atfer delimiter "(([A-Z]{3}) [-−]?\d+)[.,]([02-9]1)" $1| ir |$3|$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1| ir |$(\30)$(\2:spa) "(([A-Z]{3}) [-−]?\d+)[.,](1[0-9]|[2-9]0)" $1| ir |$3|$(\2:spa) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1| ir |$3$(\2:spb) == feminine == ([-−]?\d+) $(feminine $1) (.*)vienas \1viena (.*)du \1dvi (.*)i \1ios == masculine == ([-−]?\d+) $1 == ordinal == ([-−]?\d+) $(ordinal $1) (.*)vienas \1pirmas (.*)du \1antras (.*)trys \1trečias (.*)keturi \1ketvirtas (.*)penki \1penktas (.*)šeši \1šeštas (.*)septyni \1septintas (.*)aštuoni \1aštuntas (.*)devyni \1devintas (.*)dešimt \1dešimtas (.*)lika \1liktas (.*)šimt \1šimtas (.*) \1 # FIXME (tūkstančių etc.) == ordinal-masculine == ([-−]?\d+) $(ordinal $1) == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal $1)) (.*)tasis \1toji (.*)s \1 (.*) \1 # FIXME (tūkstančių etc.) == ordinal-number(-masculine)? == ((\d*[02-9])?3) \2-ias # ends in 3 but not 13 (\d+) \2-as == ordinal-number-feminine == ((\d*[02-9])?3) \1-ia (\d+) \1-a == help == "" $(help feminine)$(help masculine)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number-feminine)$(help ordinal-number-masculine) (feminine|masculine|ordinal(-feminine|-masculine|-number|-number-masculine|-number-feminine)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 nulle 1 viens 2 divi 3 trīs 4 četri 5 pieci 6 seši 7 septiņi 8 astoņi 9 deviņi 10 desmit 11 vienpadsmit 12 divpadsmit 13 trīspadsmit 14 četrpadsmit 15 piecpadsmit 16 sešpadsmit 17 septiņpadsmit 18 astoņpadsmit 19 deviņpadsmit (\d)(\d) $(remove-i $1)|desmit[ $2] "remove-i (.*)i" \1 "remove-i (.*)" \1 1(\d\d) simts[ $1] (\d)(\d\d) $1 simti[ $2] 1(\d{3}) viens tūkstotis[ $1] (\d{1,3})(\d{3}) $1 tūkstoši[ $2] 1(\d{6}) viens miljons[ $1] (\d{1,3})(\d{6}) $1 miljoni[ $2] 1(\d{9}) viens miljards[ $1] (\d{1,3})(\d{9}) $1 miljardi[ $2] 1(\d{12}) viens triljons[ $1] (\d{1,3})(\d{12}) $1 triljoni[ $2] 1(\d{15}) viens kvadriljons[ $1] (\d{1,3})(\d{15}) $1 kvadriljoni[ $2] 1(\d{18}) viens kvintiljons[ $1] (\d{1,3})(\d{18}) $1 kvintiljoni[ $2] 1(\d{21}) viens sekstiljons[ $1] (\d{1,3})(\d{21}) $1 sekstiljoni[ $2] 1(\d{24}) viens septiljons[ $1] (\d{1,3})(\d{24}) $1 septiljoni[ $2] # negative numbers [-−](\d+) mīnus |$1 # decimals ([-−]?\d+)[.,] $1| komats ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 LVL:(\D+) $(\1: lats, lati,latu, santīms, santīmi, santīmu) EUR:(\D+) $(\1: eiro, eiro, eiro, cents, centi, centu) RUB:(\D+) $(\1: rublis, rubļi, rubļu, kapeika, kapeikas, kapeiku) USD:(\D+) $(\1: ASV dolārs, ASV dolāri, ASV dolāru, cents, centi, centu) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?\d*[02-9]1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?[23456789])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d*[02-9][23456789])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:ug) "((RUB) [-−]?\d+)[.,]([02-9])1" $1 $(\30) |$(feminine 1)$(\2:ss) "((RUB) [-−]?\d+)[.,]([02-9][23456789])" $1 $(feminine \3)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9])1" $1 $(\30) |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9][23456789])" $1 |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sg) == feminine == ([-−]?\d+) $(feminine $1) (.*)viens viena (.*)i \1as (.*) \1 == masculine == ([-−]?\d+) $1 == ordinal == ([-−]?\d+) $(ordinal $1) (.*)viens \1pirmais (.*)divi \1otrais (.*)trīs \1trešais (.*)četri \1ceturtais (.*)pieci \1piektais (.*)seši \1sestais (.*)septiņi \1septītais (.*)astoņi \1astotais (.*)deviņi \1devītais (.*)mit \1mitais == ordinal-number == (\d+) \1. == help == "" $(help feminine)$(help masculine)$(help ordinal)$(help ordinal-number) (feminine|masculine|ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
# mr.sor for - MARATHI मराठी Indian Language (mr-IN) # In many Indian languages including MARATHI, rules of number reading (from 0 up to number 100) are complex and inconsistent. # e.g often a number is read first with units place & then ten's place. - e.g 34 read as " चौतीस " where " चौ " stands for 4 (units place) and then तीस for 30 (ten's place) which is inverse with the number reading logic in ENGLISH (where it is read as Thirty Four) # Pronunciations of numbers changes and follows virtually no logic - e.g. 54 read as " चौपन्न " where ten's place 50 is read as पन्न but only No. 50 would be read as पन्नास ! # when units place number is 9, the number is read with the reference to the NEXT number e.g. 39 is read as एकोणचाळीस where " एकोण " stands for 9 (units place) and then चाळीस with reference to 40 (the NEXT number) which is inverse with the number reading logic in ENGLISH (where it is read as Thirty Nine - reference of previous ten's place) # Reading of same units place but different ten's place is vastly different - e.g. 27 सत्तावीस , 47 सत्तेचाळीस , 67 सदुसष्ट , 77 सत्त्याहत्तर . Here same units place 7 has been read differently as सत्ता , सत्ते , सदु , सत्त्या ... very difficult to frame any logic ! # Therefore we have hard coded numbers from 0 to 100 with Marathi translations. # Number reading after Hundred's place is very similar to English logic ... hence no problem in coding for further Marathi numbers # -------------------------------------- # Number List in English , word in MARATHI # - Ankur Joshi , pharmankur@gmail.com # ^0 शून्य 1 एक 2 दोन 3 तीन 4 चार 5 पाच 6 सहा 7 सात 8 आठ 9 नऊ 10 दहा 11 अकरा 12 बारा 13 तेरा 14 चौदा 15 पंधरा 16 सोळा 17 सतरा 18 अठरा 19 एकोणीस 20 वीस 21 एकवीस 22 बावीस 23 तेवीस 24 चोवीस 25 पंचवीस 26 सव्वीस 27 सत्तावीस 28 अठ्ठावीस 29 एकोणतीस 30 तीस 31 एकतीस 32 बत्तीस 33 तेहतीस 34 चौतीस 35 पस्तीस 36 छत्तीस 37 सदतीस 38 अडतीस 39 एकोणचाळीस 40 चाळीस 41 एक्केचाळीस 42 बेचाळीस 43 त्रेचाळीस 44 चव्वेचाळीस 45 पंचेचाळीस 46 सेहेचाळीस 47 सत्तेचाळीस 48 अठ्ठेचाळीस 49 एकोणपन्नास 50 पन्नास 51 एकावन्न 52 बावन्न 53 त्रेपन्न 54 चौपन्न 55 पंचावन्न 56 छप्पन्न 57 सत्तावन्न 58 अठ्ठावन्न 59 एकोणसाठ 60 साठ 61 एकसष्ट 62 बासष्ट 63 त्रेसष्ट 64 चौसष्ट 65 पासष्ट 66 सहासष्ट 67 सदुसष्ट 68 अडुसष्ट 69 एकोणसत्तर 70 सत्तर 71 एकाहत्तर 72 बाहत्तर 73 त्र्याहत्तर 74 चौऱ्याहत्तर 75 पंचाहत्तर 76 शाहत्तर 77 सत्त्याहत्तर 78 अठ्ठ्याहत्तर 79 एकोणऐंशी 80 ऐंशी 81 एक्याऐंशी 82 ब्याऐंशी 83 त्र्याऐंशी 84 चौऱ्याऐंशी 85 पंचाऐंशी 86 शहाऐंशी 87 सत्त्याऐंशी 88 अठ्ठ्याऐंशी 89 एकोणनव्वद 90 नव्वद 91 एक्याण्णव 92 ब्याण्णव 93 त्र्याण्णव 94 चौऱ्याण्णव 95 पंचाण्णव 96 शहाण्णव 97 सत्त्याण्णव 98 अठ्ठ्याण्णव 99 नव्याण्णव 100 शंभर # ------------------------ # separator function :0+ # एक हजार :0*\d?\d " आणि " # एक हजार आणि पाच :\d+ ", " # एक कोटी, एक लाख, एक हजार दोनशेएक्केचाळीस # ------------------------ (\d)(\d\d) $1शे[ $2] # default: एकशे एक Note - The intentional space before $ in [ $2] . This is done to eliminate Zero error after 100 (\d{1,2})(\d\d\d) $1 हजार[ $2] # दहा हजार दोनशे (\d{1,2})(\d{5}) $1 लाख$(:\2)$2 # 5 zero after number thus its a LAKH [ 5th power of 10 is LAKH thus expression (\d{5}) , after this next is CRORE which is 7th power i.e. diff of 2 powers thus expression (\d{1,2}) . Foww this henceforth if in future needs to adjust Name of decimal places ] (\d{1,2})(\d{7}) $1 कोटी$(:\2)$2 # 7 zero after number thus its a CRORE (\d{1,1})(\d{9}) $1 अब्ज$(:\2)$2 # 9 zero after number thus its a ABJA (equivalant to a BILLION) (\d{1,1})(\d{10}) $1 खर्व$(:\2)$2 # 10 zero after number thus its a KHARVA (\d{1,1})(\d{11}) $1 निखर्व$(:\2)$2 # 11 zero after number thus its a NIKHARVA (\d{1,1})(\d{12}) $1 महापद्म$(:\2)$2 # 12 zero after number thus its a MAHAPADMA (equivalant to a TRILLION) (\d{1,1})(\d{13}) $1 शंकू$(:\2)$2 # 1३ zero after number thus its a SHANKU (\d{1,1})(\d{14}) $1 जलधि$(:\2)$2 # 14 zero after number thus its a JALADHI (\d{1,1})(\d{15}) $1 अन्त्य$(:\2)$2 # 15 zero after number thus its a ANTYA (equivalant to a QUADRILLION) (\d{1,1})(\d{16}) $1 मध्य$(:\2)$2 # 16 zero after number thus its a MADHYA (\d{1,50})(\d{17}) $1 परार्ध$(:\2)$2 # 17 zero after number thus its a PARARDH. Practically unlimited numbers are sumed um in Parardh. ### Above nameing for decimal places is with reference to work by BHASKARACHARYA (1150 AD) from book LILAVATI , SHLOKA (Verse) no 11 & 12 which is --> ### एक दशशत सहस्त्र अयुत लक्ष प्रयुत कोट्य: क्रमश: | ### अर्बुदम् अब्जम् खर्व निखर्व महापद्म शंकव: तस्मात्: || 11 || ### जलधिंच अन्त्यम् मध्यम् परार्धम् इति दशगुणोत्तरम् संज्ञा: | ### संख्याया: स्थानानां व्यवहारार्थम् कृता: पूर्वै: || 12 || ### ### Verse is translated as --> ### Positions of the digits from right to left are unit, ten, hundred, thousand, ten thousand, hundred thousand (lakh), million, ten million (Crore), hundred million, billion (abja), Kharva, Nikharva, Mahapadma, Sanku, Jaladhi, Antya, Madhya, Parardha. The value of each digit on the left is ten times that on the right. ### Although for practical purpose this verse goes up to parardha (17th power of 10), there are terms for numbers up to 140th power of 10 in Sanskrit. ### In todays practice wordings अयुत and प्रयुत are not used and if used are replaced by दशसहस्त्र and दशलक्ष / दशलाख respectively (Not used here) ### # ------------------------ # negative number [-−](\d+) उणे |$1 # ------------------------ # decimals 0[.,] शून्य दशांश ([-−]?\d+)[.,] $1| दशांश "([-−]?\d+[.,])([^0]\d)" $1| |$2 # e.g. एकशे वीस दशांश नऊ "([-−]?\d+[.,])(0)(0)(\d)" $1| |$2 |$3 |$4 # e.g. सदुसष्ठ दशांश शून्य शून्य नऊ "([-−]?\d+[.,])(0)(\d\d)" $1| |$2 |$3 # e.g. एकोणनव्वद दशांश शून्य एकोणनव्वद "([-−]?\d+[.,])(\d\d\d)" $1| |$2 # e.g. तेवीस दशांश पाचशे सदुसष्ठ , upto 3 places after decimal, decimals read in hundreds "([-−]?\d+[.,])(\d)(\d)(\d)(\d)" $1| |$2 |$3 |$4 |$5 # e.g. चव्वेचाळीस दशांश पाच सात दोन पाच "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # ------------------------ # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 AED:(\D+) $(\1: अमीराती दिऱ्हाम, अमीराती दिऱ्हाम, फिल्स्, फिल्स्) AUD:(\D+) $(\1: ऑस्ट्रेलिअन डॉलर, ऑस्ट्रेलिअन डॉलर्स, सेंट, सेंटस्) BGN:(\D+) $(\1: lev, leva, stotinka, stotinki) BWP:(\D+) $(\1: pula, pula, thebe, thebe) CAD:(\D+) $(\1: कॅनेडीअन डॉलर, कॅनेडीअन डॉलर्स, सेंट, सेंटस्) CHF:(\D+) $(\1: स्विस् फ्रॅंक, स्विस् फ्रॅंकस्, सेंटीम, सेंटीमस्) CNY:(\D+) $(\1: चायनीज युआन, चायनीज युआन, फेन, फेन) CZK:(\D+) $(\1: Czech koruna, Czech koruny, halér, halére) EEK:(\D+) $(\1: kroon, kroonid, sent, senti) EUR:(\D+) $(\1: युरो, युरो, सेंट, सेंटस्) GBP:(\D+) $(\1: पौंड स्टर्लिंग, पौंडस् स्टर्लिंग, पेनी, पेन्स्) GHS:(\D+) $(\1: Ghana cedi, Ghana cedis, pesewa, pesewas) GMD:(\D+) $(\1: dalasi, dalasi, butut, bututs) HKD:(\D+) $(\1: हॉन्गकॉन्ग डॉलर, हॉन्गकॉन्ग डॉलर्स, सेंट, सेंटस्) HRK:(\D+) $(\1: kuna, kuna, lipa, lipa) HUF:(\D+) $(\1: forint, forint, fillér, fillér) # --- Using Indian Rupee Symbol " ₹ " ------ INR:(\D+) $(\1: ₹ रुपया, ₹ रुपये, पैसा, पैसे) # ------------------------------------------ JMD:(\D+) $(\1: Jamaica dollar, Jamaica dollars, cent, cents) JPY:(\D+) $(\1: जपानी येन, जपानी येन, सेन, सेन) KES:(\D+) $(\1: Kenyan shilling, Kenyan shillings, cent, cents) KRW:(\D+) $(\1: Korean won, Korean won, jeon, jeon) KWD:(\D+) $(\1: कुवेती दिनार, कुवेती दिनार, फिल्स्, फिल्स्) LRD:(\D+) $(\1: Liberian dollar, Liberian dollars, cent, cents) LSL:(\D+) $(\1: loti, maloti, sente, lisente) LTL:(\D+) $(\1: litas, litai, centas, centai) LVL:(\D+) $(\1: lats, lati, santims, santimi) MGA:(\D+) $(\1: ariary, ariaries, iraimbilanja, iraimbilanja) MUR:(\D+) $(\1: Mauritian rupee, Mauritian rupees, cent, cents) MXN:(\D+) $(\1: Mexican peso, Mexican pesos, centavo, centavos) MWK:(\D+) $(\1: Malawian kwacha, Malawian kwacha, tambala, tambala) MYR:(\D+) $(\1: Ringgit, Ringgit, cent, cents) NAD:(\D+) $(\1: Namibian dollar, Namibian dollars, cent, cents) NGN:(\D+) $(\1: naira, naira, kobo, kobo) NZD:(\D+) $(\1: न्यूझीलंड डॉलर, न्यूझीलंड डॉलर्स, सेंट, सेंटस्) PGK:(\D+) $(\1: kina, kina, toea, toea) PHP:(\D+) $(\1: Philippine peso, Philippine pesos, centavo, centavos) PKR:(\D+) $(\1: पाकिस्तानी रुपया, पाकिस्तानी रुपये, पैसा, पैसे) PLN:(\D+) $(\1: zloty, zlotys, grosz, groszy) RON:(\D+) $(\1: Romanian leu, Romanian lei, ban, bani) RSD:(\D+) $(\1: Serbian dinar, Serbian dinars, para, para) RUB:(\D+) $(\1: Russian ruble, Russian rubles, kopek, kopeks) RWF:(\D+) $(\1: Rwandese franc, Rwandese francs, centime, centimes) SAR:(\D+) $(\1: सौदी रियाल, सौदी रियाल, हलाला, हलाला) SDG:(\D+) $(\1: Sudanese pound, Sudanese pounds, piastre, piastres) SGD:(\D+) $(\1: सिंगापुर डॉलर, सिंगापुर डॉलर्स, सेंट, सेंटस्) SLL:(\D+) $(\1: leone, leones, cent, cents) SZL:(\D+) $(\1: lilangeni, emalangeni, cent, cents) THB:(\D+) $(\1: baht, baht, satang, satang) TRY:(\D+) $(\1: Turkish lira, Turkish lira, kurus, kurus) TTD:(\D+) $(\1: Trinidad and Tobago dollar, Trinidad and Tobago dollars, cent, cents) TZS:(\D+) $(\1: Tanzanian shilling, Tanzanian shillings, cent, cents) UAH:(\D+) $(\1: hryvnia, hryvnia, kopiyka, kopiyka) UGX:(\D+) $(\1: Uganda shilling, Uganda shillings, cent, cents) USD:(\D+) $(\1: यु. एस. डॉलर, यु. एस. डॉलर्स, सेंट, सेंटस् ) X[AO]F:(\D+) $(\1: CFA franc, CFA francs, centime, centimes) ZAR:(\D+) $(\1: South African rand, South African rand, cent, cents) ZMK:(\D+) $(\1: Zambian kwacha, Zambian kwacha, ngwee, ngwee) ZWL:(\D+) $(\1: Zimbabwe dollar, Zimbabwe dollars, cent, cents) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 रिन "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 ज्याओ "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 फेन "((MGA|MRO) [-−]?\d+)[.,]0" $1 "((MGA|MRO) [-−]?\d+)[.,]2" $1 आणि |$(1)$(\2:ss) "((MGA|MRO) [-−]?\d+)[.,]4" $1 आणि |$(2)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]6" $1 आणि |$(3)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]8" $1 आणि |$(4)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 आणि |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 आणि |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 आणि |$3$(\2:sp) == money == "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 रिन "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 ज्याओ "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 फेन "(MGA|MRO) ([-−]?\d+)[.,]0" $2$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]2" $2 आणि 1/5$(\1:us) "(MGA|MRO) ([-−]?\d+)[.,]4" $2 आणि 2/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]6" $2 आणि 3/5$(\1:up) "(MGA|MRO) ([-−]?\d+)[.,]8" $2 आणि 4/5$(\1:up) "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) ([-−]?\d+))[.,](01)" $3 आणि 1/100$(\2:us) "(([A-Z]{3}) ([-−]?\d+))[.,](\d)" $3 आणि \40/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d)" $3 आणि \4/100$(\2:up) "(([A-Z]{3}) ([-−]?\d+))[.,](\d\d\d)" $3 आणि \4/1000$(\2:up) # ------------------------ # Ordinal ------ # Ordinal no. reading in Marathi are GENDER dependent ( and not as simple in English where anyone at no 1 will be read as FIRST ) # in Marathi there are 3 gender identities Male पुल्लिंगी , Female स्त्रिलिंगी & Neutral नपुसकलिंगी (similar to masculine, feminine, neuter in Swiss ) # ----------------------- # If a sentence refer to MALE subject equivalent of FIRST is पहिला # ordinal masculine --- पुल्लिंगी == ordinal-masculine == ([-−]?\d+) $(ordinal-masculine |$1) (.*)एक \1पहिला (.*)दोन \1दुसरा (.*)तीन \1तिसरा (.*)चार \1चौथा (.*)पाच \1पाचवा (.*)सहा \1सहावा (.*)सात \1सातवा (.*)आठ \1आठवा (.*)नऊ \1नववा (.*)दहा \1दहावा (.*)अकरा \1अकरावा (.*)बारा \1बारावा (.*)तेरा \1तेरावा (.*)चौदा \1चौदावा (.*)पंधरा \1पंधरावा (.*)सोळा \1सोळावा (.*)सतरा \1सतरावा (.*)अठरा \1अठरावा (.*)एकोणऐंशी \1एकोणऐंशीवा (.*)ऐंशी \1ऐंशीवा (.*)एक्याऐंशी \1एक्याऐंशीवा (.*)ब्याऐंशी \1ब्याऐंशीवा (.*)त्र्याऐंशी \1त्र्याऐंशीवा (.*)चौऱ्याऐंशी \1चौऱ्याऐंशीवा (.*)पंचाऐंशी \1पंचाऐंशीवा (.*)शहाऐंशी \1शहाऐंशीवा (.*)सत्त्याऐंशी \1सत्त्याऐंशीवा (.*)अठ्ठ्याऐंशी \1अठ्ठ्याऐंशीवा ([-−]?\d+)[.,](.*) $1 दशांश $(\2)वा # Ordinal of Decimals (.*) \1ावा # General Masculine Ordinal # ----------------------- # If a sentence refer to FEMALE subject equivalent of FIRST is पहिली # ordinal feminine --- स्त्रिलिंगी == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine |$1) (.*)एक \1पहिली (.*)दोन \1दुसरी (.*)तीन \1तिसरी (.*)चार \1चौथी (.*)पाच \1पाचवी (.*)सहा \1सहावी (.*)सात \1सातवी (.*)आठ \1आठवी (.*)नऊ \1नववी (.*)दहा \1दहावी (.*)अकरा \1अकरावी (.*)बारा \1बारावी (.*)तेरा \1तेरावी (.*)चौदा \1चौदावी (.*)पंधरा \1पंधरावी (.*)सोळा \1सोळावी (.*)सतरा \1सतरावी (.*)अठरा \1अठरावी (.*)एकोणऐंशी \1एकोणऐंशीवी (.*)ऐंशी \1ऐंशीवी (.*)एक्याऐंशी \1एक्याऐंशीवी (.*)ब्याऐंशी \1ब्याऐंशीवी (.*)त्र्याऐंशी \1त्र्याऐंशीवी (.*)चौऱ्याऐंशी \1चौऱ्याऐंशीवी (.*)पंचाऐंशी \1पंचाऐंशीवी (.*)शहाऐंशी \1शहाऐंशीवी (.*)सत्त्याऐंशी \1सत्त्याऐंशीवी (.*)अठ्ठ्याऐंशी \1अठ्ठ्याऐंशीवी ([-−]?\d+)[.,](.*) $1 दशांश $(\2)वी # Ordinal of Decimals (.*) \1ावी # General Feminine Ordinal # ----------------------- # If a sentence refer to NEUTRAL subject equivalent of FIRST is पहिले / पहिलं # ordinal neutral --- नपुसकलिंगी == ordinal-neutral == ([-−]?\d+) $(ordinal-neutral |$1) (.*)एक \1पहिले (.*)दोन \1दुसरे (.*)तीन \1तिसरे (.*)चार \1चौथे (.*)पाच \1पाचवे (.*)सहा \1सहावे (.*)सात \1सातवे (.*)आठ \1आठवे (.*)नऊ \1नववे (.*)दहा \1दहावे (.*)अकरा \1अकरावे (.*)बारा \1बारावे (.*)तेरा \1तेरावे (.*)चौदा \1चौदावे (.*)पंधरा \1पंधरावे (.*)सोळा \1सोळावे (.*)सतरा \1सतरावे (.*)अठरा \1अठरावे (.*)एकोणऐंशी \1एकोणऐंशीवे (.*)ऐंशी \1ऐंशीवे (.*)एक्याऐंशी \1एक्याऐंशीवे (.*)ब्याऐंशी \1ब्याऐंशीवे (.*)त्र्याऐंशी \1त्र्याऐंशीवे (.*)चौऱ्याऐंशी \1चौऱ्याऐंशीवे (.*)पंचाऐंशी \1पंचाऐंशीवे (.*)शहाऐंशी \1शहाऐंशीवे (.*)सत्त्याऐंशी \1सत्त्याऐंशीवे (.*)अठ्ठ्याऐंशी \1अठ्ठ्याऐंशीवे ([-−]?\d+)[.,](.*) $1 दशांश $(\2)वे # Ordinal of Decimals (.*) \1ावे # General Neutral Ordinal # ----------------------- # As the SUBJECT in the sentence forming is unknown and is out of scope of this code, default ordinal numbering is set to output all possible GENDERs separated by " / " , and hence may not deliver grammatically correct sentences ( we have hard coded Ordinal numbers from 1-10 with all possible GENDERs separated by " / " .. as in पहिला / पहिली / पहिले # This is done deliberately considering ease of use. # As separate commands for masculine, feminine & neutral eventhough exists, a User may not be aware. So by providing all gender words in default ordinal option, user at least will get some output of relevance. # ordinal default --- ordinal words with all gender options separated by " / " == ordinal == # Default ([-−]?\d+) $(ordinal |$1) (.*)एक \1पहिला / \1 पहिली / \1 पहिले (.*)दोन \1दुसरा / \1 दुसरी / \1 दुसरे (.*)तीन \1तिसरा / \1 तिसरी / \1 तिसरे (.*)चार \1चौथा / \1 चौथी / \1 चौथे (.*)पाच \1पाचवा / \1 पाचवी / \1 पाचवे (.*)सहा \1सहावा / \1 सहावी / \1 सहावे (.*)सात \1सातवा / \1 सातवी / \1 सातवे (.*)आठ \1आठवा / \1 आठवी / \1 आठवे (.*)नऊ \1नववा / \1 नववी / \1 नववे (.*)दहा \1दहावा / \1 दहावी / \1 दहावे (.*)अकरा \1अकरावा / \1 अकरावी / \1 अकरावे (.*)बारा \1बारावा / \1 बारावी / \1 बारावे (.*)तेरा \1तेरावा / \1 तेरावी / \1 तेरावे (.*)चौदा \1चौदावा / \1 चौदावी / \1 चौदावे (.*)पंधरा \1पंधरावा / \1 पंधरावी / \1 पंधरावे (.*)सोळा \1सोळावा / \1 सोळावी / \1 सोळावे (.*)सतरा \1सतरावा / \1 सतरावी / \1 सतरावे (.*)अठरा \1अठरावा / \1 अठरावी / \1 अठरावे (.*)एकोणऐंशी \1एकोणऐंशीवा / \1 एकोणऐंशीवी / \1 एकोणऐंशीवे (.*)ऐंशी \1ऐंशीवा / \1 ऐंशीवी / \1 ऐंशीवे (.*)एक्याऐंशी \1एक्याऐंशीवा / \1 एक्याऐंशीवी / \1 एक्याऐंशीवे (.*)ब्याऐंशी \1ब्याऐंशीवा / \1 ब्याऐंशीवी / \1 ब्याऐंशीवे (.*)त्र्याऐंशी \1त्र्याऐंशीवा / \1 त्र्याऐंशीवी / \1 त्र्याऐंशीवे (.*)चौऱ्याऐंशी \1चौऱ्याऐंशीवा / \1 चौऱ्याऐंशीवी / \1 चौऱ्याऐंशीवे (.*)पंचाऐंशी \1पंचाऐंशीवा / \1 पंचाऐंशीवी / \1 पंचाऐंशीवे (.*)शहाऐंशी \1शहाऐंशीवा / \1 शहाऐंशीवी / \1 शहाऐंशीवे (.*)सत्त्याऐंशी \1सत्त्याऐंशीवा / \1 सत्त्याऐंशीवी / \1 सत्त्याऐंशीवे (.*)अठ्ठ्याऐंशी \1अठ्ठ्याऐंशीवा / \1 अठ्ठ्याऐंशीवी / \1 अठ्ठ्याऐंशीवे ([-−]?\d+)[.,](.*) $1 दशांश $(\2)वा / $1 दशांश $(\2)वी / $1 दशांश $(\2)वे # Ordinal of Decimals (.*) \1ावा / \1ावी / \1ावे # General ALL Gender Ordinals # ----------------------- # Also we have considered to use generalized method where result for "ELEVEN" will be like - क्रमांक अकरा (similar to saying "Rank Eleven" in English in a gender neutral way.) # ordinal Sequential --- ordinal-sq == ordinal-sq == ([-−]?\d+) $(ordinal-sq |$1) (.*) क्रमांक \1 # ------------------------ # ordinal-number # Not relevant in Marathi == ordinal-number == ([-−]?\d+) $(ordinal-number |$2) (.*) \2 # ------------------------ # cardinal # Not relevant in Marathi == cardinal(-)? == ([-−]?\d+) $(cardinal |$2) (.*) \2 # ------------------------ == year == (1[0-9])00 $1शे (1[0-9])([0-9][0-9]) $1शे $2 # e.g. 1857 = अठराशे सत्तावन्न , 1947 = एकोणीसशे सत्तेचाळीस (2[0-9])([0-9][0-9]) $1शे $2 # e.g. 2021 = वीसशे एकवीस (3[0-9])([0-9][0-9]) $1शे $2 (4[0-9])([0-9][0-9]) $1शे $2 (5[0-9])([0-9][0-9]) $1शे $2 (6[0-9])([0-9][0-9]) $1शे $2 (7[0-9])([0-9][0-9]) $1शे $2 (8[0-9])([0-9][0-9]) $1शे $2 (9[0-9])([0-9][0-9]) $1शे $2 (.*) $(year-remove-and $1) # ------------------------ == year-remove-and == "(.*) and (.*)" \1 \2 (.*) \1 == help == "" $(1)|, $(2), $(3)\n$(\0 ordinal)$(\0 ordinal-masculine)$(\0 ordinal-feminine)$(\0 ordinal-neutral)$(\0 ordinal-sq)$(\0 ordinal-number)year: $(year 1999), two thousand, $(year 2001) "" \ncurrency \(for example, INR\): $(INR 2.5)\nmoney INR: $(money INR 2.5) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 kosong 1 satu 2 dua 3 tiga 4 empat 5 lima 6 enam 7 tujuh 8 lapan 9 sembilan 10 sepuluh 11 sebelas 1(\d) $1 belas (\d)(\d) $1 puluh[ $2] 1(\d\d) seratus[ $1] (\d)(\d\d) $1 ratus[ $2] 1(\d{3}) seribu[ $1] (\d{1,3})(\d{3}) $1 ribu[ $2] # sejuta or setu juta etc. (\d{1,3})(\d{6}) $1 juta[ $2] (\d{1,3})(\d{9}) $1 bilion[ $2] (\d{1,3})(\d{12}) $1 trilion[ $2] (\d{1,3})(\d{15}) $1 kuadrilion[ $2] (\d{1,3})(\d{18}) $1 kuantilion[ $2] (\d{1,3})(\d{21}) $1 sextilion[ $2] (\d{1,3})(\d{24}) $1 septilion[ $2] # negative numbers [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| koma "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit u:(.*),(.*) \1 s:(.*),(.*) \2 AUD:(.) $(\1: dollar Australia, sen) BGN:(.) $(\1: lev, leva, stotinka, stotinki) BWP:(.) $(\1: pula, pula, thebe, thebe) CAD:(.) $(\1: dollar Kanada, sen) CHF:(.) $(\1: franc Swiss, sen) CNY:(.) $(\1: yuan, fen) CZK:(.) $(\1: koruna Czech, koruna Czech, halér, halére) EEK:(.) $(\1: kroon, kroonid, sen) EUR:(.) $(\1: euro, sen) GBP:(.) $(\1: pound sterling, penny) GHS:(.) $(\1: cedi Ghana, pesewas) GMD:(.) $(\1: dalasi, bututs) HKD:(.) $(\1: dollar Hongkong, sen) IDR:(.) $(\1: rupiah, sen) INR:(.) $(\1: rupee India, paisa) JMD:(.) $(\1: dollar Jamaika, sen) JPY:(.) $(\1: yen, sen) KRW:(.) $(\1: won, chon) KES:(.) $(\1: shilling Kenya, sen) LRD:(.) $(\1: dollar Liberia, sen) LSL:(.) $(\1: loti, sente) LTL:(.) $(\1: litas, sen) LVL:(.) $(\1: lats, sen) MGA:(.) $(\1: ariary, iraimbilanja) MUR:(.) $(\1: rupee Mauritius, sen) MXN:(.) $(\1: peso Meksiko, centavo) MWK:(.) $(\1: kwacha Malawi, tambala) MYR:(.) $(\1: Ringgit, sen) NAD:(.) $(\1: dollar Namibia, sen) NGN:(.) $(\1: naira, kobo) NZD:(.) $(\1: dollar New Zealand, sen) PGK:(.) $(\1: kina, toea) PHP:(.) $(\1: peso Filipina, centavo) PKR:(.) $(\1: rupee Pakistan, paisa) PLN:(.) $(\1: zloty, grosz) RON:(.) $(\1: leu Romania, ban) RSD:(.) $(\1: dinar Serbia, para) RUB:(.) $(\1: ruble Russia, kopek) RWF:(.) $(\1: franc Rwanda, centime) SGD:(.) $(\1: dollar Singapura, sen) SLL:(.) $(\1: leone, sen) SZL:(.) $(\1: lilangeni, sen) THB:(.) $(\1: baht, satang) TRY:(.) $(\1: lira Turki, kurus) TTD:(.) $(\1: dollar Trinidad dan Tobago, sen) TZS:(.) $(\1: shilling Tanzania,sen) UAH:(.) $(\1: hryvnia, kopiyka) UGX:(.) $(\1: shilling Uganda, sen) USD:(.) $(\1: dolar Amerika, sen) ZAR:(.) $(\1: rand Afrika Selatan, sen) ZMK:(.) $(\1: kwacha Zambia, ngwee) ZWL:(.) $(\1: dollar Zimbabwe, sen) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 yiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 dan $(\30)$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 dan $3$(\2:s) == ordinal == 1 pertama (\d+) $(ordinal ke$1) "kesatu (.*)" kese\1 (.*) \1 == ordinal-number == 1 1 (\d+) ke-\1 == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 xejn # żero 1 wieħed 2 tnejn 3 tlieta 4 erbgħa 5 ħamsa 6 sitta 7 sebgħa 8 tmienja 9 disgħa 10 għaxra 11 ħdax 12 tnax 13 tlettax 14 erbatax 15 ħmistax 16 sittax 17 sbatax 18 tmintax 19 dsatax 2(\d) [$1 u ]għoxrin 3(\d) [$1 u ]tletin 4(\d) [$1 u ]erbgħin 5(\d) [$1 u ]ħamsin 6(\d) [$1 u ]sittin 7(\d) [$1 u ]sebgħin 8(\d) [$1 u ]tmenin 9(\d) [$1 u ]disgħin 1(\d\d) mija[ $1] 2(\d\d) mitejn[ $1] 3(\d\d) tliet mija[ $1] 4(\d\d) erba’ mija[ $1] 5(\d\d) hames mija[ $1] 6(\d\d) sitt mija[ $1] 7(\d\d) seba’ mija[ $1] 8(\d\d) tminn mija[ $1] 9(\d\d) disa’ mija[ $1] 1(\d{1,3}) elf[ $1] 2(\d{1,3}) elfejn[ $1] 3(\d{1,3}) tlitt elef[ $1] 4(\d{1,3}) erbat elef[ $1] 5(\d{1,3}) ħamest elef[ $1] 6(\d{1,3}) sitt elef[ $1] 7(\d{1,3}) sebat elef[ $1] 8(\d{1,3}) tmint elef[ $1] 9(\d{1,3}) disat elef[ $1] (\d{1,3})(\d\d\d) $1 elf[ $2] (\d{1,3})(\d{6}) $1 miljun[ $2] (\d{1,3})(\d{9}) $1 biljun[ $2] (\d{1,3})(\d{12}) $1 triljun[ $2] == cardinal-feminine == 1 waħda (.*) $1 == cardinal-masculine == (.*) $1 == ordinal == 1 l-ewwel 2 it-tieni 3 it-tielet 4 ir-raba’g 5 il-ħames 6 is-sitt 7 is-seba’g 8 it-tmien 9 id-disa’g 10 l-għaxar 11 il-ħdax 12 it-tnax 13 it-tlettax 14 l-erbatax 15 il-ħmistax 16 is-sittax 17 is-sbatax 18 it-tmintax 19 id-dsatax 20 l-għoxrin (.*) \1 == ordinal-number == (.*) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal)$(help ordinal-number) (cardinal(-feminine|-masculine)?|ordinal(-number)?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0$ nul 1$ een 1 eenen 2$ twee 2 tweeën 3$ drie 3 drieën 4$ vier 4 vieren 5$ vijf 5 vijfen 6$ zes 6 zesen 7$ zeven 7 zevenen 8$ acht 8 achten 9$ negen 9 negenen 10 tien 11 elf 12 twaalf 13 dertien 14 veertien 1(\d) $1|tien 2(\d) $1twintig 3(\d) $1dertig 4(\d) $1veertig 8(\d) $1tachtig (\d)(\d) $2$1|tig 1(\d\d) honderd$1 (\d)(\d\d) $1|honderd$2 10(\d{2}) duizend[ $1] (\d)0(\d{2}) $1|duizend[ $2] (1\d)(\d{2}) $1|honderd$2 (\d\d)(\d{2}) $1|honderd$2 (\d{2,3})(\d{3}) $1|duizend[ $2] (\d{1,3})(\d{6}) $1| miljoen[ $2] (\d{1,3})(\d{9}) $1| miljard[ $2] (\d{1,3})(\d{12}) $1| biljoen[ $2] (\d{1,3})(\d{15}) $1| biljard[ $2] (\d{1,3})(\d{18}) $1| triljoen[ $2] (\d{1,3})(\d{21}) $1| triljard[ $2] # negative number [-−](\d+) min |$1 # decimals ([-−]?\d+)[.,] $1| komma ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currencies # unit/subunit u:([^,]*),([^,]*),([^,]*) \1 s:([^,]*),([^,]*),([^,]*) \2 p:([^,]*),([^,]*),([^,]*) \3 CHF:(.) $(\1: Zwitserse franc, centime, centimes) CNY:(.) $(\1: renminbi yuan, fen, fen) EUR:(.) $(\1: euro, cent, cent) GBP:(.) $(\1: pond sterling, penny, pence) JPY:(.) $(\1: yen, sen, sen) USD:(.) $(\1: Amerikaanse dollar, cent, cent) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2| rin "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:u) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2| jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2| fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 een$(\2:s) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)|$(\2:p) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3|$(\2:p) == ordinal == ([-−]?([24-79]|\d*1\d|\d+0[24-79])) $1|de ([-−]?\d+) $(ordinal |$1) (.*)een \1eerste (.*)drie \1derde (.*) \1ste == ordinal-number == ([-−]?([2-79]|\d*1\d|\d+0[2-79])) \1de ([-−]?\d+) \1ste == help == "" $(1)|, $(2)|, $(3)|\n$(\0 ordinal)$(\0 ordinal-number)currency \(for example, EUR\): $(EUR 2.5) "(ordinal(-number)?)" \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 null 1 éin # [:nn:] [:nn-NO:] 1 én 2 to 3 tre 4 fire 5 fem 6 seks 7 sju 8 åtte 9 ni 10 ti 11 elleve 12 tolv 13 tretten 14 fjorten 15 femten 16 seksten 17 sytten 18 atten 19 nitten 2(\d) tjue[$1] 3(\d) tretti[$1] 4(\d) førti[$1] 5(\d) femti[$1] 6(\d) seksti[$1] 7(\d) sytti[$1] 8(\d) åtti[$1] 9(\d) nitti[$1] (\d)(\d\d) $(cardinal-neuter \1) hundre[ og $2] (\d{1,3})(\d{3}) $(cardinal-neuter \1) tusen[ og $2] a:1,0+ a:\d+,0+ er a:1,(\d+) " og $1" a:\d+,(\d+) "er og $1" (\d{1,3})(\d{6}) $1 million$(a:\1,\2) (\d{1,3})(\d{9}) $1 milliard$(a:\1,\2) (\d{1,3})(\d{12}) $1 billion$(a:\1,\2) (\d{1,3})(\d{15}) $1 billiard$(a:\1,\2) (\d{1,3})(\d{18}) $1 trillion$(a:\1,\2) (\d{1,3})(\d{21}) $1 trilliard$(a:\1,\2) (\d{1,3})(\d{24}) $1 kvadrillion$(a:\1,\2) # negative number [-−](\d+) minus |$1 # decimals ([-−]?\d+)[.,] $1| komma "([-−]?\d+[.,]0*)(\d+)" $1 |$2 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 CHF:(\D+) $(\1: sveitsisk franc, sveitsisk franc, centime, centimes) CNY:(\D+) $(\1: renminbi yuan, renminbi yuan, fen, fen) DKK:(\D+) $(\1: dansk krone, danske kroner, øre, øre) EUR:(\D+) $(\1: euro, euro, cent, cent) GBP:(\D+) $(\1: britisk pund, britisk pund, penny, pence) ISK:(\D+) $(\1: islandsk krone, islandske kroner, eyrir, aurar) JPY:(\D+) $(\1: yen, yen, sen, sen) NOK:(\D+) $(\1: norsk krone, norske kroner, øre, øre) SEK:(\D+) $(\1: svensk krone, svenske kroner, øre, øre) USD:(\D+) $(\1: amerikansk dollar, amerikansk dollar, cent, cent) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:up) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sp) == cardinal-feminine == 1 éi == cardinal-neuter == 1 eitt # [:nn:] [:nn-NO:] 1 ett == cardinal(-feminine|-masculine|-neuter)? == (.*\d+) $2 == ordinal == ([-−]?\d+) $(ordinal |$1) null nullte # 0 (éi?n) første # 1 "(.*) én" \1 først # 1 (.*)to \1annen # 2 (.*)tre \1tredje # 3 (.*)fire \1fjerde # 4 (.*(fem|ellev|tolv|ard|on))(e|er)? \1te # 5, 11, 12, 10^6, 10^9 etc. (.*)seks \1sjette # 6 (.*)tres \1tressende # 60 (.*(sju|ått|ni|ti|tju|ti))e? \1ende # 7, 8, 9, 10, 20, 30, 40, 50, 70, 80, 90 (.*(en|hundre|tusen)) \1de # 13-19, 100, 1000 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help cardinal-neuter)$(help ordinal)$(help ordinal-number) (cardinal(-feminine|-masculine|-neuter)?|ordinal(-number)?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 zero 1 jeden 2 dwa 3 trzy 4 cztery 5 pięć 6 sześć 7 siedem 8 osiem 9 dziewięć 10 dziesięć 11 jedenaście 14 czternaście 15 piętnaście 16 szesnaście 19 dziewiętnaście 1(\d) $1naście 2(\d) dwadzieścia[ $1] 3(\d) trzydzieści[ $1] 4(\d) czterdzieści[ $1] (\d)(\d) $1dziesiąt[ $2] 1(\d\d) sto[ $1] 2(\d\d) dwieście[ $1] ([34])(\d\d) $1sta[ $2] (\d)(\d\d) $1set[ $2] 1(\d{3}) tysiąc[ $1] ([234]|[2-9][234]|\d[02-9][234])(\d{3}) $1 tysiące[ $2] (\d{1,3})(\d{3}) $1 tysięcy[ $2] # affix function :1,(.+) \1 :(1[1-9]),(.+) $1 \2ów :([234]|[2-9][234]|\d[02-9][234]),(.+) $1 \2y :(\d+),(.+) $1 \2ów (\d{1,3})(\d{6}) $(:\1,milion)[ $2] (\d{1,3})(\d{9}) $(:\1,miliard)[ $2] (\d{1,3})(\d{12}) $(:\1,bilion)[ $2] (\d{1,3})(\d{15}) $(:\1,biliard)[ $2] (\d{1,3})(\d{18}) $(:\1,trylion)[ $2] (\d{1,3})(\d{21}) $(:\1,tryliard)[ $2] (\d{1,3})(\d{24}) $(:\1,kwadrylion)[ $2] # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| przecinek "([-−]?\d+[.,])([^0]\d)" $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular / nominative plural / genitive plural us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 AUD:(\D+) $(\1: dolar australijski, dolary australijskie, dolarów australijskich, cent, centy, centów) BGN:(\D+) $(\1: lew bułgarski, lewy bułgarskie, lewów bułgarskich, stotinka, stotinki, stotinek) CHF:(\D+) $(\1: frank szwajcarski, franki szwajcarskie, franków szwajcarskich, centym, centymy, centymów) CAD:(\D+) $(\1: dolar kanadyjski, dolary kanadyjskie, dolarów kanadyjskich, cent, centy, centów) CNY:(\D+) $(\1: juan, juany, juanów, fen, feny, fenów) EUR:(\D+) $(\1: euro, euro, euro, cent, centy, centów) GBP:(\D+) $(\1: funt szterling, funty szterlingi, funtów szterlingów, pens, pensy, pensów) HUF:(\D+) $(\1: forint, forinty, forintów, filler, fillery, fillerów) JPY:(\D+) $(\1: jen, jeny, jenów, sen, seny, senów) PLN:(\D+) $(\1: złoty, złote, złotych, grosz, grosze, groszy) RUB:(\D+) $(\1: rubel rosyjski, ruble rosyjskie, rubli rosyjskich, kopiejka, kopiejki, kopiejek) USD:(\D+) $(\1: dolar amerykański, dolary amerykańskie, dolarów amerykańskich, cent, centy, centów) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?[234])([.,]00?)?" $2$(\1:up) "([A-Z]{3}) ([-−]?\d*[02-9][234])([.,]00?)?" $2$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:ug) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fenów "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9][234])" $1 |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sg) == ordinal(-masculine)? == ([-−]?\d+) $(ordinal |$2) "(.*)siąt (.*)" $(ordinal \2siąty \3) "(.*)eści (.*)" $(ordinal \2esty \3) "(.*)dwadzieścia (.*)" $(ordinal \2dwudziesty \3) (.*)dwadzieścia \2dwudziesty (.*)jeden \2pierwszy (.*)dwa \2drugi (.*)trzy \2trzeci (.*)cztery \2czwarty (.*)pięć \2piąty (.*)sześć \2szósty (.*)siedem \2siódmy (.*)osiem \2ósmy (.*)dziewięć \2dziewiąty (.*)dziesięć \2dziesiąty (.*)jedenaście \2jedenasty (.*)dwanaście \2dwunasty (.*)dwieście \2dwusetny (.*)siąt \2siąty (.*)trzysta \2trzechsetny (.*)czterysta \2czterechsetny (.*)ści[ea] \2sty (.*)eści \2esty (.*)(sto|set) \2setny "(.*)dwa tysiące" \2dwutysięczny "(.*)pięć tysięcy" \2pięciotysięczny "(.*)sto tysięcy" \2stutysięczny "(.*) (tysi[ąę]c[ey]?)" \2tysięczny (.*)tysiąc \2tysięczny (.*(on|ard))(y|ów)? \2owy == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal |$1)) "(.*)[yi] (.*)" $(ordinal-feminine \1a \2) (.*)[yi] \1a == ordinal-neuter == ([-−]?\d+) $(ordinal-neuter $(ordinal |$1)) "(.*)[yi] (.*)" $(ordinal-neuter \1e \2) (.*)[yi] \1e == ordinal-number == (\d+) \1. == help == "" $(1), $(2), $(3)\n$(help ordinal)$(help ordinal-number) (ordinal(-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 zero 1 um 2 dois 3 três 4 quatro 5 cinco 6 seis 7 sete 8 oito 9 nove 10 dez 11 onze 12 doze 13 treze 14 quatorze 15 quinze 16 dezesseis # [:pt-BR:] 16 dezasseis 17 dezessete # [:pt-BR:] 17 dezassete 18 dezoito 19 dezenove # [:pt-BR:] 19 dezanove 20 vinte 30 trinta 40 quarenta 50 cinquenta 60 sessenta 70 setenta 80 oitenta 90 noventa (\d)(\d) $(\10) e $2 100 cem 1(\d\d) cento e $1 2(\d\d) duzentos[ e $1] 3(\d\d) trezentos[ e $1] 5(\d\d) quinhentos[ e $1] (\d)(\d\d) $1centos[ e $2] :0+ :0*\d{1,2}(\d{6}){0,} " e " # mil e um, mil e dez :0*\d00(\d{6}){0,} " e " # mil e quinhentos :0*\d{1,2}000(\d{6}){0,} " e " # um milhão e onze mil :0*\d{1}00000(\d{6}){0,} " e " # um milhão e cem mil :\d+ " " pl:1 ão # milhão pl:.* ões # milhões 1(\d\d\d) mil$(:\1)$1 (\d{1,3})(\d\d\d) $1 mil$(:\2)$2 (\d{1,3})(\d{6}) $1 milh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{9}) $1 bilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{12}) $1 trilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{15}) $1 quatrilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{18}) $1 quintilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{18}) $1 sextilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,3})(\d{24}) $1 septilh$(pl:\1)$(:\2)$2 # [:pt-BR:] (\d{1,6})(\d{6}) $1 milh$(pl:\1)$(:\2)$2 (\d{1,6})(\d{12}) $1 bili$(pl:\1)$(:\2)$2 (\d{1,6})(\d{18}) $1 trili$(pl:\1)$(:\2)$2 (\d{1,6})(\d{24}) $1 quatrili$(pl:\1)$(:\2)$2 # negative number [-−](\d\d*) menos |$1 # decimals ([-−]?\d+)[.] $1| ponto ([-−]?\d+)[,] $1| vírgula ([-−]?\d+[.,])([^0]\d) $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" |$1 |$2| |$3| |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency (monedas) # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 AOA:(\D+) $(\1: kwanza, kwanzas, cêntimo, cêntimos) ARG:(\D+) $(\1: peso argentino, pesos argentinos, centavo, centavos) BOB:(\D+) $(\1: boliviano, bolivianos, centavo, centavos) BRL:(\D+) $(\1: real, reais, centavo, centavos) # [:pt-BR:] BRL:(\D+) $(\1: real, réis, centavo, centavos) CHF:(\D+) $(\1: franco suíço, francos suíços, cêntimo, cêntimos) CNY:(\D+) $(\1: yuan renminbi, yuan renminbi, fen, fen) CVE:(\D+) $(\1: escudos cabo-verdianos, escudos cabo-verdianos, centavo, centavos) EUR:(\D+) $(\1: euro, euros, cent, cents) GBP:(\D+) $(\1: libra esterlina, libras esterlinas, penny, pence) JPY:(\D+) $(\1: iene, ienes, sen, sen) MOP:(\D+) $(\1: pataca, patacas, avo, avos) MXN:(\D+) $(\1: peso mexicano, pesos mexicanos, centavo, centavos) MZM:(\D+) $(\1: metical, meticais, centavo, centavos) STD:(\D+) $(\1: dobra, dobras, cêntimo, cêntimos) USD:(\D+) $(\1: dólar americano, dólares americanos, cêntimo, cêntimos) XOF:(\D+) $(\1: franco CFA, francos CFA, cêntimo, cêntimos) # masculine to feminine conversion of "un" after millions, # if "as?$" matches currency name f:(.*il[hi])(.*),(.*) \1$(f:\2,\3) # don't modify millions f:(.*um)([^a].*,|,)(.*as?) $(f:\1a\2\3) # um libra -> uma libra f:(.*d)oi(s.*),(.*as?) $(f:\1ua\2,\3) # dois libra -> duas libra f:(.*ent)o(s.*),(.*as?) $(f:\1a\2,\3) # duzentos libra -> duzentas libra f:(.*),(.*) \1\2 "([A-Z]{3}) ([-−]?1)([.,]00?)?"$(f:|$2,$(\1:us)) "([A-Z]{3}) ([-−]?\d+0{6,})([.,]00?)?" $2 de$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(f:|$2,$(\1:up)) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 e |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 e |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 e |$3$(\2:sp) == feminine == ([-−]?\d+) $(feminine $1) (.*)um \1uma (.*)dois(.*) $(feminine \1duas\2) (.*) \1 == masculine == ([-−]?\d+) $1 == ordinal(-masculine)? == 1 primeiro 2 segundo 3 terceiro 4 quarto 5 quinto 6 sexto 7 sétimo 8 oitavo 9 nono 10 décimo 20 vigésimo 30 trigésimo 40 cuadragésimo 50 quincuagésimo 60 sexagésimo 70 septuagésimo 80 octogésimo 90 nonagésimo (\d)(\d) $(ordinal \20) $(ordinal \3) 100 centésimo 200 ducentésimo 300 trecentésimo 400 quadrigentésimo 500 quingentésimo 600 sexcentésimo 700 septicentésimo 800 octigentésimo 900 nongentésimo (\d)(\d\d) $(ordinal \200) $(ordinal \3) 1(\d{3}) milésimo[ $(ordinal \2)] (\d)(\d{3}) $2 milésimo[ $(ordinal \3)] 1(\d{6}) milionésimo[ $(ordinal \2)] (\d{1,3})(\d{6}) $2 milionésimo[ $(ordinal \3)] 1(\d{9}) bilionésimo[ $(ordinal \2)] (\d{1,3})(\d{9}) $2 bilionésimo[ $(ordinal \3)] == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal-masculine \1)) (.*)o\b(.*) $(ordinal-feminine \1a\2) (.*) \1 == (ordinal)-number(-feminine|-masculine)? == ([-−]?\d+) \3$(ordinal-number $(\1\2 \3)) .*er .ᵉʳ .*a .ª .*o .º == help == "" $(1)|, $(2), $(3)\n$(\0 feminine)$(\0 masculine)$(\0 ordinal-feminine)$(\0 ordinal-masculine)$(\0 ordinal-number-feminine)$(\0 ordinal-number-masculine) (feminine|masculine|ordinal(-number)?(-feminine|-masculine)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 zero 1 unu 2$ doi 2 două 3 trei 4 patru 5 cinci 6$ șase 6 șai 7 șapte 8 opt 9 nouă 10 zece 11 unsprezece 12 doisprezece 14 paisprezece 1(\d) $1sprezece (\d)(\d) $1zeci[ și $2] 1(\d\d) o sută[ $1] (\d)(\d\d) $1 sute[ $2] 1(\d{3}) o mie[ $1] (1?\d)(\d{3}) $1 mii[ $2] (\d{1,3})(\d{3}) $1 de mii[ $2] 1(\d{6}) un milion[ $1] (1?\d)(\d{6}) $1 milioane[ $2] (\d{1,3})(\d{6}) $1 de milioane[ $2] 1(\d{9}) un miliard[ $1] (1?\d)(\d{9}) $1 miliarde[ $2] (\d{1,3})(\d{9}) $1 de miliarde[ $2] 1(\d{12}) un trilion[ $1] (1?\d)(\d{12}) $1 trilioane[ $2] (\d{1,3})(\d{12}) $1 de trilioane[ $2] 1(\d{15}) un cvadrilion[ $1] (1?\d)(\d{15}) $1 cvadrilioane[ $2] (\d{1,3})(\d{15}) $1 de cvadrilioane[ $2] 1(\d{18}) un cvintilion[ $1] (1?\d)(\d{18}) $1 cvintilioane[ $2] (\d{1,3})(\d{18}) $1 de cvintilioane[ $2] 1(\d{21}) un sextilion[ $1] (1?\d)(\d{21}) $1 sextilioane[ $2] (\d{1,3})(\d{21}) $1 de sextilioane[ $2] 1(\d{24}) un septilion[ $1] (1?\d)(\d{24}) $1 septilioane[ $2] (\d{1,3})(\d{24}) $1 de septilioane[ $2] # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| virgulă "([-−]?\d+[.,])([^0]\d)" $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # feminine/masculine correction for 1 and 2 f:(.*)unu \1 o f:(.*do)i "\1uă " m:(.*un)u \1 .:(.*) \1 # unit/subunit, singular/plural, feminine/masculine unit, feminine/masculine subunit us(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \2 up(.).:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \3 ss.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \4 sp.(.):([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) $(\1:\6) \5 # "mm" means masculine unit and masculine subunit CHF:(.+),(.+) $(\1mm: franc elvețian, franci elvețieni, cent, cenți, \2) CNY:(.+),(.+) $(\1mm: yuan renminbi, yuani renminbi, fen, fen, \2) EUR:(.+),(.+) $(\1mm: euro, euro, cent, cenți, \2) GBP:(.+),(.+) $(\1fm: liră sterlină, lire sterline, penny, pence, \2) JPY:(.+),(.+) $(\1mm: yen, yeni, sen, sen, \2) RON:(.+),(.+) $(\1mm: leu românesc, lei românești, ban, bani, \2) USD:(.+),(.+) $(\1mm: dolar american, dolari americani, cent, cenți, \2) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $(-remove-extra-space $(\1:us,|$2)) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $(-remove-extra-space $(\1:up,|$2)) "(CNY [-−]?\d+)[.,]10?" $1| un jiao "(CNY [-−]?\d+)[.,](\d)0?" $1| $2| jiao "(CNY [-−]?\d+[.,]\d)1" $1| $2| fen "(CNY [-−]?\d+[.,]\d)(\d)" $1| $2| fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $(-remove-extra-space $1|$(\2:ss,$(1))) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $(-remove-extra-space $1|$(\2:sp,$(\30))) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $(-remove-extra-space $1|$(\2:sp,$3)) == -remove-extra-space == "^ (.*)" $(-remove-extra-space \1) "(.*) ( .*)" \1\2 (.*) \1 == ordinal(-masculine)? == 1 primul ([-−]?\d+) al $(ordinal $2) (.*(opt|ilion|ard)) \2ulea (.*) \2lea == ordinal-feminine == 1 prima ([-−]?\d+) a $(ordinal-feminine $1) (.*)doi \1doua (.*)cinci \1cincea (.*)[uă] \1a (.*)sute \1suta (.*)mi[ei] \1mia (.*)ane \1ana (.*) \1a == ordinal-number == (\d+) \1. == help == "" $(1), |$(2)|, $(3)\n$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number) (ordinal(-feminine|-masculine|-number)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 ноль 1 один 2 два 3 три 4 четыре 5 пять 6 шесть 7 семь 8 восемь 9 девять 10 десять 11 одиннадцать 12 двенадцать 13 тринадцать 14 четырнадцать 15 пятнадцать 16 шестнадцать 17 семнадцать 18 восемнадцать 19 девятнадцать ([23])(\d) $1|дцать[ $2] 4(\d) сорок[ $1] 9(\d) девяносто[ $1] (\d)(\d) $1десят[ $2] 1(\d\d) сто[ $1] 2(\d\d) двести[ $1] ([34])(\d\d) $1ста[ $2] (\d)(\d\d) $1сот[ $2] (1|\d?[02-9]1)(\d{3}) $(f:$1) тысяча[ $2] ([234]|\d?[02-9][234])(\d{3}) $(f:$1) тысячи[ $2] (\d{1,3})(\d{3}) $1 тысяч[ $2] (1|\d?[02-9]1)(\d{6}) $1 миллион[ $2] ([234]|\d?[02-9][234])(\d{6}) $1 миллиона[ $2] (\d{1,3})(\d{6}) $1 миллионов[ $2] (1|\d?[02-9]1)(\d{9}) $1 миллиард[ $2] ([234]|\d?[02-9][234])(\d{9}) $1 миллиарда[ $2] (\d{1,3})(\d{9}) $1 миллиардов[ $2] (1|\d?[02-9]1)(\d{12}) $1 триллион[ $2] ([234]|\d?[02-9][234])(\d{12}) $1 триллиона[ $2] (\d{1,3})(\d{12}) $1 триллионов[ $2] (1|\d?[02-9]1)(\d{15}) $1 квадриллион[ $2] ([234]|\d?[02-9][234])(\d{15}) $1 квадриллиона[ $2] (\d{1,3})(\d{15}) $1 квадриллионов[ $2] (1|\d?[02-9]1)(\d{18}) $1 квинтиллион[ $2] ([234]|\d?[02-9][234])(\d{18}) $1 квинтиллиона[ $2] (\d{1,3})(\d{18}) $1 квинтиллионов[ $2] (1|\d?[02-9]1)(\d{21}) $1 секстилион[ $2] ([234]|\d?[02-9][234])(\d{21}) $1 секстилиона[ $2] (\d{1,3})(\d{21}) $1 секстилионов[ $2] (1|\d?[02-9]1)(\d{24}) $1 септиллион[ $2] ([234]|\d?[02-9][234])(\d{24}) $1 септиллиона[ $2] (\d{1,3})(\d{24}) $1 септиллионов[ $2] # negative numbers [-−]1 минус единица [-−](\d+) минус |$1 # decimals "([-−]?)[.,](\d+)" $(\10.\2) "[-−]1[.,]" минус одна целая "([-−]?\d+[02-9]1|1)[.,]" $(f:|$1) целая "([-−]?\d+)[.,]" $(f:|$1) целых "([-−]?\d+[.,])1" $1| и одна десятая "([-−]?\d+[.,])(\d)" $1| и $(f:|$2) десятых "([-−]?\d+[.,])([02-9]1)" $1| и $(f:|$2) сотая "([-−]?\d+[.,])(\d\d)" $1| и $(f:|$2) сотых "([-−]?\d+[.,])(\d[02-9]1)" $1| и $(f:|$2) тысячная "([-−]?\d+[.,])(\d{3})" $1| и $(f:|$2) тысячных "([-−]?\d+[.,])(\d)(\d)(\d)(\d)" $1| |$2 |$3 |$4 |$5 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # female conversion f:(.*)один \1одна f:(.*)два \1две f:(.*) \1 # neuter conversion n:(.*)один \1одно n:(.*) \1 # possessive (1-999) - used in ordinals "pos:(.* )?од(ин|на) ?" [$(pos:\1)]одно "pos:(.* )?дв[ае] ?" [$(pos:\1)]двух "pos:(.* )?три ?" [$(pos:\1)]трёх "pos:(.* )?четыре ?" [$(pos:\1)]четырёх "pos:(.* )?восемь ?" [$(pos:\1)]восьми "pos:(.* )?([а-я]+)ь ?" [$(pos:\1)]\2и "pos:(.* )?сорок ?" [$(pos:\1)]сорока "pos:(.* )?восемьдесят ?" [$(pos:\1)]восьмидесяти "pos:(.* )?([а-я]+)ьдесят ?" [$(pos:\1)]\2идесяти "pos:(.* )?([а-я]*)сто ?" [$(pos:\1)]\2сто "pos:(.*)двести ?" \1двухсот "pos:(.*)[еи]ста ?" \1ёхсот "pos:(.*)осемьсот ?" \1осьмисот "pos:(.*)ьсот ?" \1исот pos:(.*) \1 # currency # unit/subunit us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 EUR:(\D+) $(\1: евро, евро, евро, цент, цента, центов) GBP:(\D+) $(\1: фунт стерлингов, фунта стерлингов, фунтов стерлингов, пенни, пенса, пенсов) RUB:(\D+) $(\1: рубль, рубля, рублей, копейка, копейки, копеек) UAH:(\D+) $(\1: гривна, гривны, гривен, копейка, копейки, копеек) USD:(\D+) $(\1: доллар США, доллара США, долларов США, цент, цента, центов) "(UAH) ([-−]?1)([.,]00?)?" $(f:$2)|$(\1:us) "(UAH) ([-−]?\d*[02-9]1)([.,]00?)?" $(f:$2)|$(\1:us) "(UAH) ([-−]?[234])([.,]00?)?" $(f:$2)|$(\1:up) "(UAH) ([-−]?\d*[02-9][234])([.,]00?)?" $(f:$2)|$(\1:up) "(UAH) ([-−]?\d+)([.,]00?)?" $(f:$2)|$(\1:ug) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?\d*[02-9]1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?[234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d*[02-9][234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:ug) "((RUB) [-−]?\d+)[.,]([02-9])1" $1 [$(\30) ]одна$(\2:ss) "((RUB) [-−]?\d+)[.,]([02-9])2" $1 [$(\30) ]две$(\2:sp) "((UAH) [-−]?\d+)[.,]([02-9])1" $1 [$(\30) ]одна$(\2:ss) "((UAH) [-−]?\d+)[.,]([02-9])2" $1 [$(\30) ]две$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "((EUR|GBP|USD) [-−]?\d+)[.,]([02-9]1)" $1 $3|$(\2:ss) "((EUR|GBP|USD) [-−]?\d+)[.,]([02-9]2)" $1 $3|$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9][234])" $1 |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sg) == cardinal-masculine? == (.*) $(\1) == cardinal-feminine == (.*) $(f:$1) == cardinal-neuter == (.*) $(n:$1) == ordinal-feminine == 0 нулевая ([-−]?\d+) $(ordinal-feminine |$1) (.*)один \1первая (.*)два \1вторая (.*)три \1третья (.*)ыре \1вёртая (.*)осемь \1осьмая (.*)мь \1дьмая (.*)ь \1ая (.*)к \1ковая (.*)осемьдесят \1осьмидесятая (.*)ьдесят \1идесятая (.*)осто \1остая (.*)сто \1сотая (.*)вести \1вухсотая (.*)[еи]ста \1ёхсотая (.*)осемьсот \1осьмисотая (.*)ьсот \1исотая "одна тысяча" тысячная "(.* )тысяч[аи]?" $(pos:\1)тысячная "один (\w+илли\w+)" \1ная "(.* )([а-я]+илли[а-я]+)(а|ов)" $(pos:\1)\2ная "(.* )([а-я]+илли[а-я]+)" $(pos:\1)\2ная (.*) \1ая == ordinal-neuter == 0 нулевое ([-−]?\d+) $(ordinal-neuter |$1) (.*)один \1первое (.*)два \1второе (.*)три \1третье (.*)ыре \1вёртое (.*)осемь \1осьмое (.*)мь \1дьмое (.*)ь \1ое (.*)к \1ковое (.*)осемьдесят \1осьмидесятое (.*)ьдесят \1идесятое (.*)осто \1остое (.*)сто \1сотое (.*)вести \1вухсотое (.*)[еи]ста \1ёхсотое (.*)осемьсот \1осьмисотое (.*)ьсот \1исотое "одна тысяча" тысячное "(.* )тысяч[аи]?" $(pos:\1)тысячное "один ([а-я]+илли[а-я]+)" \1ное "(.* )([а-я]+илли[а-я]+)(а|ов)" $(pos:\1)\2ное "(.* )([а-я]+илли[а-я]+)" $(pos:\1)\2ное (.*) \1ое == ordinal(-masculine)? == 0 нулевой ([-−]?\d+) $(ordinal |$2) (.*)один \2первый (.*)два \2второй (.*)три \2третий (.*)ыре \2вёртый (.*)сть \2стой (.*)осемь \2осьмой (.*)мь \2дьмой (.*)ь \2ый (.*)к \2ковой (.*)осемьдесят \2осьмидесятый (.*)ьдесят \2идесятый (.*)осто \2остый (.*)сто \2сотый (.*)вести \2вухсотый (.*)[еи]ста \2ёхсотый (.*)осемьсот \2осьмисотый (.*)ьсот \2исотый "одна тысяча" тысячный "(.* )тысяч[аи]?" $(pos:\2)тысячный "один ([а-я]+илли[а-я]+)" \2ный "(.* )([а-я]+илли[а-я]+)(а|ов)" $(pos:\2)\3ный "(.* )([а-я]+илли[а-я]+)" $(pos:\2)\3ный (.*) \2ый == ordinal-number-feminine == (\d+) \1-я == ordinal-number-neuter == (\d+) \1-е == ordinal-number(-masculine)? == (\d+) \2-й == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help cardinal-neuter)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-neuter)$(help ordinal-number-feminine)$(help ordinal-number-masculine)$(help ordinal-number-neuter) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
# # Regular number to text transducer for Serbian (Cyrillic) written in Soros # Copyright (c) Goran Rakic
2009. # # Released under Creative Commons 3.0 Attribution - Share Alike license # and relicensed under GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Visit http://numbertext.org for more info on Soros language and syntax # (\d{1,3})\.([\d.,]+) $(\1\2) ^0 nula 1 jedan 2 dva 3 tri 4 četiri 5 pet 6 šest 7 sedam 8 osam 9 devet 10 deset 11 jedanaest 14 četrnaest 16 šesnaest 1(\d) $1naest 4(\d) četrdeset[ $1] 5(\d) pedeset[ $1] 6(\d) šezdeset[ $1] 9(\d) devedeset[ $1] (\d)(\d) $1deset[ $2] 1(\d\d) sto[ $1] 2(\d\d) dvesta[ $1] 3(\d\d) trista[ $1] (\d)(\d\d) $1sto[ $2] 1(\d\d\d) hiljadu[ $1] 2(\d\d\d) dve hiljade[ $1] ([34])(\d\d\d) $1 hiljade[ $2] (\d{0,1})1(\d)(\d\d\d) $(\11\2) hiljada[ $3] (\d{1,2})1(\d\d\d) $(\10) jedna hiljada[ $2] (\d{1,2})2(\d\d\d) $(\10) dve hiljade[ $2] (\d{1,2})([34])(\d\d\d) $(\10) $2 hiljade[ $3] (\d{1,3})(\d\d\d) $1 hiljada[ $2] 1(\d{6}) milion[ $1] (\d{0,4})1(\d)(\d{6}) $(\11\2) miliona[ $3] (\d{1,5})1(\d{6}) $(\10) jedan milion[ $2] (\d{1,3})(\d{6}) $1 miliona[ $2] 1(\d{9}) milijarda[ $1] 2(\d{9}) dve milijarde[ $1] ([34])(\d{9}) $1 milijarde[ $2] (\d{1,2})0(\d{9}) $(\10) milijardi[ $2] (\d{0,1})1(\d)(\d{9}) $(\11\2) milijardi[ $3] (\d{1,2})1(\d{9}) $(\10) jedna milijarda[ $2] (\d{1,2})2(\d{9}) $(\10) dve milijarde[ $2] (\d{1,2})([34])(\d{9}) $(\10) $2 milijarde[ $3] (\d{1,3})(\d{9}) $1 milijarde[ $2] 1(\d{12}) bilion[ $1] (\d{0,4})1(\d)(\d{12}) $(\11\2) biliona[ $3] (\d{1,5})1(\d{12}) $(\10) jedan bilion[ $2] (\d{1,6})(\d{12}) $1 biliona[ $2] 1(\d{18}) trilion[ $1] (\d{0,4})1(\d)(\d{18}) $(\11\2) triliona[ $3] (\d{1,5})1(\d{18}) $(\10) jedan trilion[ $2] (\d{1,6})(\d{18}) $1 triliona[ $2] 1(\d{24}) kvadrilion[ $1] (\d{0,4})1(\d)(\d{24}) $(\11\2) kvadriliona[ $3] (\d{1,5})1(\d{24}) $(\10) jedan kvadrilion[ $2] (\d{1,6})(\d{24}) $1 kvadriliona[ $2] 1(\d{30}) kvintilion[ $1] (\d{0,4})1(\d)(\d{30}) $(\11\2) kvintiliona[ $3] (\d{1,5})1(\d{30}) $(\10) jedan kvintilion[ $2] (\d{1,6})(\d{30}) $1 kvintiliona[ $2] 1(\d{36}) sekstilion[ $1] (\d{0,4})1(\d)(\d{36}) $(\11\2) sekstiliona[ $3] (\d{1,5})1(\d{36}) $(\10) jedan sekstilion[ $2] (\d{1,6})(\d{36}) $1 sekstiliona[ $2] [-−](\d+) minus $1 # Decimal code by https://twitter.com/_uranium_ "([-−]?\d+)," $1| koma "([-−]?\d+,)([^0]\d)" $1 $2 "([-−]?\d+,\d*[1-9]?)0+$" $1 "([-−]?\d+,)(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+,\d*)(\d)" $1 |$2 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 nula 1 jeden 2 dva ^2$ dve 3 tri 4 štyri 5 päť 6 šesť 7 sedem 8 osem 9 deväť 10 desať 11 jedenásť 14 štrnásť 15 pätnásť 19 devätnásť 1(\d) $1násť ([234])(\d) $1dsať[ $2] 5(\d) päťdesiat[ $1] 6(\d) šesdesiat[ $1] 9(\d) devädesiat[ $1] (\d)(\d) $1desiat[ $2] 1(\d\d) sto[ $1] ([234])(\d\d) $1sto[ $2] (\d)(\d\d) $1sto[ $2] 1(\d\d\d) tisíc[ $1] (\d{1,3})(\d\d\d) $1 tisíc[ $2] 1(\d{6}) milión[ $1] ([234])(\d{6}) $1 milióny[ $2] (\d{1,3})(\d{6}) $1 miliónov[ $2] 1(\d{9}) miliarda[ $1] ([234])(\d{9}) $1 miliardy[ $2] (\d{1,3})(\d{9}) $1 miliárd[ $2] 1(\d{12}) bilión[ $1] ([234])(\d{12}) $1 bilióny[ $2] (\d{1,3})(\d{12}) $1 biliónov[ $2] 1(\d{15}) biliarda[ $1] ([234])(\d{15}) $1 biliardy[ $2] (\d{1,3})(\d{15}) $1 biliárd[ $2] 1(\d{18}) trilión[ $1] ([234])(\d{18}) $1 trilióny[ $2] (\d{1,3})(\d{18}) $1 triliónov[ $2] 1(\d{21}) triliarda[ $1] ([234])(\d{21}) $1 triliardy[ $2] (\d{1,3})(\d{21}) $1 triliárd[ $2] 1(\d{24}) kvadrilión[ $1] ([234])(\d{24}) $1 kvadrilióny[ $2] (\d{1,3})(\d{24}) $1 kvadriliónov[ $2] # negative number [-−](\d+) mínus |$1 # decimals ([-−]?\d+)[.,] $1| celých ([-−]?\d+[.,])([^0]\d) $1| |$2 ([-−]?\d+[.,])(\d)(\d)(\d) $1| |$2 |$3 |$4 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular / plural / plural genitiv us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 ugender:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \7 sgender:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \8 CHF:(\D+) $(\1: švajčiarsky frank, švajčiarske franky, švajčiarskych frankov, cent, centy, centov,masculine,masculine) CNY:(\D+) $(\1: jüan, jüany, jüanů, fen, feny, fenů,masculine,masculine) CZK:(\D+) $(\1: koruna česká, koruny české, korún českých, halier, haliere, halierov,feminine,masculine) EUR:(\D+) $(\1: euro, eurá, eur, cent, centy, centov,neuter,masculine) GBP:(\D+) $(\1: britská libra, britské libry, britské liber, penca, pence, pencí,feminine,feminine) JPY:(\D+) $(\1: jen, jeny, jenov, sen, seny, senov,masculine,masculine) RUB:(\D+) $(\1: rubeľ, ruble, rublov, kopejka, kopejky, kopejok,masculine,feminine) SKK:(\D+) $(\1: slovenská koruna, slovenské koruny, slovenských korún, halier, haliere, halierov,feminine,masculine) USD:(\D+) $(\1: americký dolár, americké doláre, amerických dolárov, cent, centy, centov,masculine,masculine) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:us) "([A-Z]{3}) ([-−]?[2-4])([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $(cardinal-$(\1:ugender) \2)$(\1:ug) "(CNY [-−]?\d+)[.,]10?" $1 $(cardinal-neuter 1) ťiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $(cardinal-neuter \2) ťiao "((CNY) [-−]?\d+[.,]\d)1" $1 $(cardinal-masculine 1)$(\2:ss) "((CNY) [-−]?\d+[.,]\d)(2|3|4)" $1 $(cardinal-masculine \3)$(\2:sp) "((CNY) [-−]?\d+[.,]\d)(\d)" $1 $(cardinal-masculine \3)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](00)" $1 $(cardinal-$(\2:sgender) \1)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 $(cardinal-$(\2:sgender) \3)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](02|03|04)" $1 $(cardinal-$(\2:sgender) \3)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $(cardinal-$(\2:sgender) \3)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(cardinal-$(\2:sgender) \30)$(\2:sg) == cardinal-neuter == 1 jedno 2 dve (.*) $1 == cardinal-feminine == 1 jedna 2 dve (.*) $1 == cardinal-masculine == 1 jeden (.*) $1 == ordinal == ([-−]?\d+) $(ordinal |$1) "(.*)dvesto(.*)" $(ordinal \1dvojstý\2) "(.*)tristo(.*)" $(ordinal \1trojstý\2) "(.*)štyristo(.*)" $(ordinal \1štvorstý\2) "(.*)(päť|šesť|sedem|osem|deväť)sto(.*)" $(ordinal \1\2stý\3) nula nultý (.*)(jedno|jedna|jeden) $(ordinal \1prvý) (.*)(jedenásť) $(ordinal \1jedenásty) (.*)(dva|dve) $(ordinal \1druhý) (.*)(dve|dva)\b(.*) $(ordinal \1druhý\3) (.*)tri\b(.*) $(ordinal \1tretí\2) (.*)štyri\b(.*) $(ordinal \1štvrtý\2) (.*)päť\b(.*) $(ordinal \1piaty\2) "(.*)(šesť|sedem|osem|desiat|násť|siat)( .+|$)" $(ordinal \1\2y\3) (.*)deväť\b(.*) $(ordinal \1deviaty\2) "(.*)sto\b(.*)" $(ordinal \1\2iaty\3) (.*)sto\b(.*) $(ordinal \1stý\2) (.*)tisíc?(.*) \1tisíci\2 (.*)milión(y|ov)(.*) \1miliónty\2 (.*)miliard[ay]?(.*) \1miliardtý\2 (.*) \1 == ordinal-masculine == (.*) $(ordinal |$1) == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine |$(ordinal-masculine \1)) (.*)ý(.*) $(ordinal-feminine \1á\2) (.*)[yi](.*) $(ordinal-feminine \1a\2) (.*)tretí(.*) $(ordinal-feminine \1tretia\2) (.*) \1 == ordinal-neuter == ([-−]?\d+) $(ordinal-neuter |$(ordinal-masculine \1)) (.*)ý(.*) $(ordinal-neuter \1é\2) (.*)[yi](.*) $(ordinal-neuter \1e\2) (.*)tretí(.*) $(ordinal-feminine \1tretie\2) (.*) \1 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-neuter)$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal)$(help ordinal-masculine)$(help ordinal-feminine)$(help ordinal-neuter)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 nič 1 ena 2$ dve 2 dva 3 tri 4 štiri 5 pet 6 šest 7 sedem 8 osem 9 devet 10 deset 11 enajst 1(\d) $1najst 20 dvajset 2(\d) $1indvajset (\d)0 $1deset (\d)(\d) $2in$1deset 1(\d\d) sto[ $1] 2(\d\d) dvesto[ $1] (\d)(\d\d) $1sto[ $2] 1(\d\d\d) tisoč[ $1] (\d{1,3})(\d\d\d) $1 tisoč[ $2] 1(\d{6}) milijon[ $1] ([234])(\d{6}) $1 milijona[ $2] (\d{1,3})(\d{6}) $1 milijonov[ $2] 1(\d{9}) milijarda[ $1] ([234])(\d{9}) $1| milijardi[ $2] (\d{1,3})(\d{9}) $1 milijardov[ $2] 1(\d{12}) bilijon[ $1] ([234])(\d{12}) $1 bilijona[ $2] (\d{1,3})(\d{12}) $1 bilijonov[ $2] 1(\d{15}) tisoč bilijonov[ $1] (\d{1,3})(\d{15}) $1 tisoč bilijonov[ $2] 1(\d{18}) trilijon[ $1] ([234])(\d{18}) $1 trilijona[ $2] (\d{1,3})(\d{18}) $1 trilijonov[ $2] 1(\d{21}) tisoč trilijonov[ $1] (\d{1,3})(\d{21}) $1 tisoč trilijonov[ $2] 1(\d{24}) kvadrilijon[ $1] ([234])(\d{24}) $1 kvadrilijona[ $2] (\d{1,3})(\d{24}) $1 kvadrilijonov[ $2] # negative number [-−] minus [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| vejica "([-−]?\d+[.,])([^0]\d)" $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit affixation u1:([^,]*)(,[^,]*){9} \1 u2:([^,]*,){1}([^,]*)(,[^,]*){8} \2 u3:([^,]*,){2}([^,]*)(,[^,]*){7} \2 u4:([^,]*,){3}([^,]*)(,[^,]*){6} \2 u5:([^,]*,){4}([^,]*)(,[^,]*){5} \2 s1:([^,]*,){5}([^,]*)(,[^,]*){4} \2 s2:([^,]*,){6}([^,]*)(,[^,]*){3} \2 s3:([^,]*,){7}([^,]*)(,[^,]*){2} \2 s4:([^,]*,){8}([^,]*)(,[^,]*){1} \2 s5:([^,]*,){9}([^,]*) \2 CHF:(.+) $(\1: švicarski frank, švicarska franka, švicarski franki, švicarske franke, švicarskih frankov, centim, centima, centimi, centime, centimov) EUR:(.+) $(\1: evro, evra, evri, evre, evrov, cent, centa, centi, cente, centov) GBP:(.+) $(\1: funt šterling, funta šterlinga, funti šterlingi, funte šterlinge, funtov šterlingov, peni, penija, peniji, penije, penijev) JPY:(.+) $(\1: japonski jen, japonska jena, japonski jeni, japonske jene, japonskih jenov, sen, sena, seni, sene, senov) USD:(.+) $(\1: ameriški dolar, ameriška dolarja, ameriški dolarji, ameriške dolarje, ameriških dolarjev, cent, centa, centi, cente, centov) "([A-Z]{3}) ([-−]?)1([.,]00?)?" $2 en$(\1:u1) "([A-Z]{3}) ([-−]?\d*01)([.,]00?)?" $2$(\1:u1) "([A-Z]{3}) ([-−]?(2|\d*02))([.,]00?)?" $2$(\1:u2) "([A-Z]{3}) ([-−]?(3|\d*03))([.,]00?)?" $2$(\1:u3) "([A-Z]{3}) ([-−]?(4|\d*04))([.,]00?)?" $2$(\1:u4) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2$(\1:u5) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 en$(\2:s1) "(([A-Z]{3}) [-−]?\d+)[.,](02)" $1 $3$(\2:s2) "(([A-Z]{3}) [-−]?\d+)[.,](03)" $1 $3$(\2:s3) "(([A-Z]{3}) [-−]?\d+)[.,](04)" $1 $3$(\2:s4) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\30)$(\2:s5) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $3$(\2:s5) == cardinal-feminine == (\d+) $1 == cardinal-neuter == (\d+) $(cardinal-neuter |$1) (.*)ena \1eno (.*) \1 == cardinal-masculine == (\d+) $(cardinal-masculine |$1) (.*)ena \1eden (.*)dve \1dva (.*tri) \1je (.*) \1 == cardinal-adverbial == (\d+) $(cardinal-adverbial |$1) (.*)ena \1enkrat (.*)dve \1dvakrat (.*) \1krat == ordinal(-masculine)? == (\d+) $(ordinal |$2) "(.*) (.*)" $(ordinal \2\3) # remove spaces (.*)ena \2prvi (.*)dve \2drugi (.*)tri \2tretji (.*)štiri \2četrti (.*) \2i == ordinal-feminine == (\d+) $(ordinal-feminine $(ordinal \1)) (.*)i \1a == ordinal-neuter == (\d+) $(ordinal-neuter $(ordinal \1)) (.*)i \1o == ordinal-adverbial == (\d+) $(ordinal |$1)č == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help cardinal-neuter)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-neuter)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0$ zero 1 një 2 dy 3 tre 4 katër 5 pesë 6 gjashtë 7 shtatë 8 tetë 9 nëntë 1(\d) [$1mbë]dhjetë 2(\d) njëzet[ e $1] 4(\d) dyzet[ e $1] (\d)(\d) $(cardinal-feminine \1)dhjetë[ e $2] (\d)(\d\d) $1qind[ e $2] (\d{1,3})(\d{3}) $1 mijë[ $2] (1)(\d{6}) $(cardinal-feminine \1) milion[ $2] (\d{1,3})(\d{6}) $(cardinal-feminine \1) milionë[ $2] (1)(\d{9}) $(cardinal-feminine \1) miliar[ $2] (\d{1,3})(\d{9}) $(cardinal-feminine \1) miliarë[ $2] (1)(\d{12}) $(cardinal-feminine \1) trilion[ $2] (\d{1,3})(\d{12}) $(cardinal-feminine \1) trilionë[ $2] # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" "$1| presje" "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 ALL:(\D+) $(\1: lek, lekë, qindarka, qindarka) EUR:(\D+) $(\1: euro, euro, cent, cent) GBP:(\D+) $(\1: paund sterlina, paund sterlina, peni, peni) USD:(\D+) $(\1: dollari amerikan, dollarë amerikanë, cent, cent) "([A-Z]{3}) ([-−]?1)" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)" $2$(\1:up) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sp) == cardinal-feminine == 3 tri (\d+) $(cardinal-feminine $1) (.*)tre \1tri (.*) \1 == cardinal(-masculine)? == (\d+) $2 == ordinal-feminine == (\d+) e $(ordinal-feminine $1) (.*)një \1para (.*)të \1ta (.*)ë \1ta (.*) \1ta == ordinal(-masculine)? == (\d+) i $(ordinal $2) (.*)një \2pari (.*)të \2ti (.*)ë \2ti (.*) \2ti == ordinal-number == (.*) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
# # Regular number to text transducer for Serbian (Cyrillic) written in Soros # Copyright (c) Goran Rakic
2009. # # Released under Creative Commons 3.0 Attribution - Share Alike license # and relicensed under GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Visit http://numbertext.org for more info on Soros language and syntax # (\d{1,3})\.([\d.,]+) $(\1\2) ^0 нула 1 један 2 два 3 три 4 четири 5 пет 6 шест 7 седам 8 осам 9 девет 10 десет 11 једанаест 14 четрнаест 16 шеснаест 1(\d) $1наест 4(\d) четрдесет[ $1] 5(\d) педесет[ $1] 6(\d) шездесет[ $1] 9(\d) деведесет[ $1] (\d)(\d) $1десет[ $2] 1(\d\d) сто[ $1] 2(\d\d) двеста[ $1] 3(\d\d) триста[ $1] (\d)(\d\d) $1сто[ $2] 1(\d\d\d) хиљаду[ $1] 2(\d\d\d) две хиљаде[ $1] ([34])(\d\d\d) $1 хиљаде[ $2] (\d{0,1})1(\d)(\d\d\d) $(\11\2) хиљада[ $3] (\d{1,2})1(\d\d\d) $(\10) једна хиљада[ $2] (\d{1,2})2(\d\d\d) $(\10) две хиљаде[ $2] (\d{1,2})([34])(\d\d\d) $(\10) $2 хиљаде[ $3] (\d{1,3})(\d\d\d) $1 хиљада[ $2] 1(\d{6}) милион[ $1] (\d{0,4})1(\d)(\d{6}) $(\11\2) милиона[ $3] (\d{1,5})1(\d{6}) $(\10) један милион[ $2] (\d{1,3})(\d{6}) $1 милиона[ $2] 1(\d{9}) милијарда[ $1] 2(\d{9}) две милијарде[ $1] ([34])(\d{9}) $1 милијарде[ $2] (\d{1,2})0(\d{9}) $(\10) милијарди[ $2] (\d{0,1})1(\d)(\d{9}) $(\11\2) милијарди[ $3] (\d{1,2})1(\d{9}) $(\10) једна милијарда[ $2] (\d{1,2})2(\d{9}) $(\10) две милијарде[ $2] (\d{1,2})([34])(\d{9}) $(\10) $2 милијарде[ $3] (\d{1,3})(\d{9}) $1 милијарде[ $2] 1(\d{12}) билион[ $1] (\d{0,4})1(\d)(\d{12}) $(\11\2) билионa[ $3] (\d{1,5})1(\d{12}) $(\10) један билион[ $2] (\d{1,6})(\d{12}) $1 билиона[ $2] 1(\d{18}) трилион[ $1] (\d{0,4})1(\d)(\d{18}) $(\11\2) трилиона[ $3] (\d{1,5})1(\d{18}) $(\10) један трилион[ $2] (\d{1,6})(\d{18}) $1 трилиона[ $2] 1(\d{24}) квадрилион[ $1] (\d{0,4})1(\d)(\d{24}) $(\11\2) квадрилиона[ $3] (\d{1,5})1(\d{24}) $(\10) један квадрилион[ $2] (\d{1,6})(\d{24}) $1 квадрилиона[ $2] 1(\d{30}) квинтилион[ $1] (\d{0,4})1(\d)(\d{30}) $(\11\2) квинтилиона[ $3] (\d{1,5})1(\d{30}) $(\10) један квинтилион[ $2] (\d{1,6})(\d{30}) $1 квинтилиона[ $2] 1(\d{36}) секстилион[ $1] (\d{0,4})1(\d)(\d{36}) $(\11\2) секстилиона[ $3] (\d{1,5})1(\d{36}) $(\10) један секстилион[ $2] (\d{1,6})(\d{36}) $1 секстилиона[ $2] [-−](\d+) минус $1 # Decimal code by https://twitter.com/_uranium_ "([-−]?\d+)," $1| кома "([-−]?\d+,)([^0]\d)" $1 $2 "([-−]?\d+,\d*[1-9]?)0+$" $1 "([-−]?\d+,)(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+,\d*)(\d)" $1 |$2 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 noll ^1$ ett ^1 en 1 ett 2 två 3 tre 4 fyra 5 fem 6 sex 7 sju 8 åtta 9 nio 10 tio 11 elva 12 tolv 13 tretton 14 fjorton 15 femton 16 sexton 17 sjutton 18 arton 19 nitton 2(\d) tjugo$1 3(\d) trettio$1 4(\d) fyrtio$1 7(\d) sjuttio$1 8(\d) åttio$1 9(\d) nittio$1 (\d)(\d) $1tio$2 (\d)(\d\d) $1|hundra$2 # “ettusen” instead of “etttusen” (1|\d?[02-9]1)(\d{3}) $1|usen[ $2] (\d{1,3})(\d{3}) $1tusen[ $2] (\d{1,3})(\d{6}) |$1 miljon$(pl:\1)[ $2] (\d{1,3})(\d{9}) |$1 miljard$(pl:\1)[ $2] (\d{1,3})(\d{12}) |$1 biljon$(pl:\1)[ $2] (\d{1,3})(\d{15}) |$1 biljard$(pl:\1)[ $2] (\d{1,3})(\d{18}) |$1 triljon$(pl:\1)[ $2] (\d{1,3})(\d{21}) |$1 triljard$(pl:\1)[ $2] (\d{1,3})(\d{24}) |$1 kvadriljon$(pl:\1)[ $2] # plural for big numbers pl:1 pl:.* er # negative number [-−](\d+) minus |$1 # decimals "([-−]?\d+)[.,]" $1| komma "([-−]?\d+[.,])([^0]\d)" $1| |$2 "([-−]?\d+[.,])(\d)(\d)(\d)" $1| |$2 |$3 |$4 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # currency # unit/subunit singular/plural "us, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\2 \1) \3 "up, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\2 \1) \4 "ss, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\5 \1) \6 "sp, (.*): (.*), (.*), (.*), (.*), (.*), (.*)" $(\5 \1) \7 CHF:(\D+,.*) $(\1: cardinal, schweizisk franc, schweizisk franc, cardinal, centime, centime) CNY:(\D+,.*) $(\1: cardinal, yuan renminbi, yuan renminbi, cardinal, fen, fen) EUR:(\D+,.*) $(\1: cardinal, euro, euro, cardinal-neuter, cent, cent) GBP:(\D+,.*) $(\1: cardinal-neuter, brittiskt pund, brittiskt pund, cardinal, penny, pence) JPY:(\D+,.*) $(\1: cardinal, yen, yen, cardinal, sen, sen) SEK:(\D+,.*) $(\1: cardinal, svensk krona, svenska kronor, cardinal-neuter, öre, öre) USD:(\D+,.*) $(\1: cardinal, US-dollar, US-dollar, cardinal-neuter, cent, cent) "([A-Z]{3}) ([-−]?1)([.,]00?)?"$(\1:us, \2) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?"$(\1:up, \2) "(CNY [-−]?\d+)[.,]10?" $1 $2 jiao "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)1" $1 $2 fen "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 $(\2:ss, 1) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 $(\2:sp, \30) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $(\2:sp, \3) == cardinal-neuter == 1 ett == cardinal(-feminine|-masculine|-neuter)? == ([-−]?\d+) $(cardinal |$2) "(.*[^ ]e)t(tusen.*)" $(cardinal \2n\3) # 21000, 31000 .. 991000 "(.*e)tt([ ].*|$)" $(cardinal \2n\3) # !etthundra, !ettusen (.*) \2 == ordinal(-masculine)? == ([-−]?\d+) $(ordinal |$2) == ordinal == (.*)ett \1förste # 1 (.*)två \1andre # 2 (.*)tre \1tredje # 3 (.*)fyra \1fjärde # 4 (.*)sex \1sjätte # 6 (.*(sju|io)) \1nde # 7, 9, 10, 20..90 (.*)åtta \1åttonde # 8 (.*)elva \1elfte # 11 (.*)tolv \1tolfte # 12 "(.*(ton|hundra|tusen)) *" \1de # 13, 14..19, 100, 1000 "(.*)er *" \1te # milljoner... "(.*[^ ]) *" \1te # 0, 5, milljon... == ordinal-feminine == ([-−]?\d+) $(ordinal-feminine $(ordinal |$1)) (.*(först|andr))e \1a # 1, 2 (.*) \1 == ordinal-neuter == (.*) $(ordinal-feminine |$1) == ordinal-number(-feminine|-neuter)? == (.*[02-9][12]|[12]) \2:a == ordinal-number(-feminine|-neuter|-masculine)? == (.*) \2:e == year == ([-−]?(1[1-9]|[2-9]\d))(\d\d) $1hundra$3 (.*) $1 == help == "" $(1)|, $(2), $(3)\n$(\0 cardinal-feminine)$(\0 cardinal-masculine)$(\0 cardinal-neuter)$(\0 ordinal-feminine)$(\0 ordinal-masculine)$(\0 ordinal-neuter)$(\0 ordinal-number)$(\0 ordinal-number-feminine)$(\0 ordinal-number-masculine) ((ordinal|cardinal)(-number)?(-feminine|-masculine|-neuter)?) \1: $(\1 1), $(\1 2), $(\1 3)\n
^0 ศูนย์ ^1$ หนึ่ง 1$ เอ็ด 1 หนึ่ง 2 สอง 3 สาม 4 สี่ 5 ห้า 6 หก 7 เจ็ด 8 แปด 9 เก้า 1(\d) สิบ$1 2(\d) ยี่สิบ$1 (\d)(\d) $1สิบ$2 (\d)(\d\d) $1ร้อย$2 (\d)(\d{3}) $1พัน$2 (\d)(\d{4}) $1หมื่น$2 (\d)(\d{5}) $1แสน$2 (\d{1,6})(\d{6}) $1|ล้าน$2 (\d{1,6})(\d{12}) $1|ล้านล้าน$2 (\d{1,6})(\d{18}) $1|ล้านล้านล้าน$2 (\d)(\d{24}) $1|ล้านล้านล้านล้าน$2 # negative numbers [-−](\d+) ลบ|$1 # decimals ([-−]?\d+)[.,] |$1|จุด ([-−]?\d+[.,]\d*)(\d) |$1|$2 # currency "THB ([-−]?\d+)" |$1|บาทถ้วน # currency with decimals "(THB [-−]?\d+)[,.]00" $1 "THB ([-−]?\d+)[.,](\d{1})" |$1|บาท$(\20)สตางค์ "THB ([-−]?\d+)[,.](\d{1,2})" |$1|บาท|$2|สตางค์ # other currencies? [A-Z]{3} "([A-Z]{3}) ([-−]?\d[\d.,]*)" $2$1 == ordinal == ([-−]?\d+([.,]\d+)?) ที่$1 == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 sıfır 1 bir 2 iki 3 üç 4 dört 5 beş 6 altı 7 yedi 8 sekiz 9 dokuz 1(\d) on[ $1] 2(\d) yirmi[ $1] 3(\d) otuz[ $1] 4(\d) kırk[ $1] 5(\d) elli[ $1] 6(\d) altmış[ $1] 7(\d) yetmiş[ $1] 8(\d) seksen[ $1] 9(\d) doksan[ $1] (1)(\d\d) yüz[ $2] # yüz .. ([2-9])(\d\d) $1 yüz[ $2] # üç yüz ... (1)(\d\d\d) bin[ $2] # bin (\d{1,2})([1-9]\d\d) $1 bin[ $2] # on bin iki yüz (\d{1,3})(\d{3}) $1 bin[ $2] # yüz bin iki yüz (\d{1,3})(\d{6}) $1 milyon[ $2] (\d{1,3})(\d{9}) $1 milyar[ $2] (\d{1,3})(\d{12}) $1 trilyon[ $2] (\d{1,3})(\d{15}) $1 katrilyon[ $2] (\d{1,3})(\d{18}) $1 kentilyon[ $2] (\d{1,3})(\d{21}) $1 sekstilyon[ $2] (\d{1,3})(\d{24}) $1 septilyon[ $2] # negative number [-−](\d+) negatif |$1 # decimals ([-−]?\d+)[.,] $1| virgül "([-−]?\d+[.,]0*)(\d+)" $1 |$2 ([-−]?\d+[.,]\d*)(\d) $1| |$2 # currency # unit/subunit singular/plural us:([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*) \2 ss:([^,]*),([^,]*),([^,]*),([^,]*) \3 sp:([^,]*),([^,]*),([^,]*),([^,]*) \4 AUD:(\D+) $(\1: Avustralya doları, Avustralya doları, sent, sent) BGN:(\D+) $(\1: Bulgar levası, Bulgar levası, stotinka, stotinki) BWP:(\D+) $(\1: Botswana pulası, Botswana pulası, thebe, thebe) CAD:(\D+) $(\1: Kanada doları, Canadian dollars, sent, sent) CHF:(\D+) $(\1: İsviçre frangı, İsviçre frangı, santim, santim) CNY:(\D+) $(\1: Çin yuanı, Çin yuanı, fen, fen) CZK:(\D+) $(\1: Çek korunası, Çek korunası, heller, heller) EEK:(\D+) $(\1: Estonya kronu, Estonya kronu, sent, sent) EUR:(\D+) $(\1: euro, euro, sent, sent) GBP:(\D+) $(\1: sterlin, sterlin, peni, peni) GHS:(\D+) $(\1: Gana sedisi, Gana sedisi, peseva, peseva) GMD:(\D+) $(\1: Gambiya dalası, Gambiya dalası, butut, butut) HKD:(\D+) $(\1: Hong Kong doları, Hong Kong doları, sent, sent) HRK:(\D+) $(\1: Hırvatistan kunası, Hırvatistan kunası, lipa, lipa) HUF:(\D+) $(\1: Macar forinti, Macar forinti, filler, filler) INR:(\D+) $(\1: Hindistan rupisi, Hindistan rupisi, paise, paise) JMD:(\D+) $(\1: Jamaika doları, Jamaika doları, sent, sent) JPY:(\D+) $(\1: Japon yeni, Japon yeni, sen, sen) KES:(\D+) $(\1: Kenya şilini, Kenya şilini, sent, sent) LRD:(\D+) $(\1: Liberya doları, Liberya doları, sent, sent) LSL:(\D+) $(\1: Lesotho loti, maloti, sente, lisente) LTL:(\D+) $(\1: Litvanya litası, Litvanya litası, centas, centai) LVL:(\D+) $(\1: Letonya latı, Letonya latı, santims, santimi) MGA:(\D+) $(\1: ariary, ariaries, iraimbilanja, iraimbilanja) MUR:(\D+) $(\1: Mauritius rupisi, Mauritius rupisi, sent, sent) MXN:(\D+) $(\1: Meksika pezosu, Meksika pezosu, sentavo, sentavo) MWK:(\D+) $(\1: Malawian kwacha, Malawian kwacha, tambala, tambala) NAD:(\D+) $(\1: Namibya doları, Namibya doları, sent, sent) NGN:(\D+) $(\1: Nijerya nairası, Nijerya nairası, kobo, kobo) NZD:(\D+) $(\1: Yeni Zelanda doları, Yeni Zelanda doları, sent, sent) PGK:(\D+) $(\1: Papua Yeni Gine kinası, Papua Yeni Gine kinası, toea, toea) PHP:(\D+) $(\1: Filipinler pezosu, Filipinler pezosu, sentavo, sentavo) PKR:(\D+) $(\1: Pakistan rupisi, Pakistan rupisi, paisa, paisa) PLN:(\D+) $(\1: Polonya zlotisi, Polonya zlotisi, grosz, groszy) RON:(\D+) $(\1: Romen leyi, Romen leyi, ban, ban) RSD:(\D+) $(\1: Sırbistan dinarı, Sırbistan dinarı, para, para) RUB:(\D+) $(\1: Rus rublesi, Rus rublesi, kopek, kopek) RWF:(\D+) $(\1: Ruanda frangı, Ruanda frangı, santim, santim) SDG:(\D+) $(\1: Sudan poundu, Sudan poundu, piastre, piastres) SGD:(\D+) $(\1: Singapur doları, Singapur doları, sent, sent) SLL:(\D+) $(\1: Sierra Leone leonu, Sierra Leone leonu, sent, sent) SZL:(\D+) $(\1: lilangeni, emalangeni, cent, cents) THB:(\D+) $(\1: Tayland bahtı, Tayland bahtı, satang, satang) TRY:(\D+) $(\1: Türk lirası, Türk lirası, kuruş, kuruş) TTD:(\D+) $(\1: Trinidad ve Tobago doları, Trinidad ve Tobago doları, sent, sent) TZS:(\D+) $(\1: Tanzanya şilini, Tanzanya şilini, sent, sent) UAH:(\D+) $(\1: Ukrayna hryvnyası, Ukrayna hryvnyası, kopiyka, kopiyka) UGX:(\D+) $(\1: Uganda şilini, Uganda şilini, sent, sent) USD:(\D+) $(\1: ABD doları, ABD doları, sent, sent) X[AO]F:(\D+) $(\1: CFA franc, CFA francs, centime, centimes) ZAR:(\D+) $(\1: Güney Afrika randı, Güney Afrika randı, sent, sent) ZMK:(\D+) $(\1: Zambiya kıvaçası, Zambiya Kıvaçası, ngwee, ngwee) ZWD:(\D+) $(\1: Zimbabve doları, Zimbabve doları, sent, sent) "(JPY [-−]?\d+)[.,](\d\d)0" $1 "(JPY [-−]?\d+[.,]\d\d)(\d)" $1 $2 rin # removing spaces from number names before currencies "space:([^ ]+) +([^ ].*)" \1$(space:\2) space:(.*) \1 "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2$(\1:us) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $(space:|$2)$(\1:up) "(CNY [-−]?\d+)[.,](\d)0?" $1 $2 jiao "(CNY [-−]?\d+[.,]\d)(\d)" $1 $2 fen "((MGA|MRO) [-−]?\d+)[.,]0" $1 "((MGA|MRO) [-−]?\d+)[.,]2" $1 |$(1)$(\2:ss) "((MGA|MRO) [-−]?\d+)[.,]4" $1 |$(2)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]6" $1 |$(3)$(\2:sp) "((MGA|MRO) [-−]?\d+)[.,]8" $1 |$(4)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 $(space:|$3)$(\2:sp) == ordinal == (\d+) $(ordinal $1) (.*ü[çz]) \1üncü (.*dör)t \1düncü (.*)altı \1altıncı (.*(kırk|doksan|yar|ış)) \1ıncı (.*(uz|on)) \1uncu (.*)i \1inci (.*) \1inci == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal)$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0 нуль 1 один 2 два 3 три 4 чотири 5$ пʼять 5 пʼят 6$ шість 6 шіст 7 сім 8 вісім 9$ девʼять 9 девʼят 10 десять 11 одинадцять 12 дванадцять 13 тринадцять 14 чотирнадцять 15 пʼятнадцять 16 шістнадцять 17 сімнадцять 18 вісімнадцять 19 девʼятнадцять ([23])(\d) $1|дцять[ $2] 4(\d) сорок[ $1] 9(\d) девʼяносто[ $1] (\d)(\d) $1десят[ $2] 1(\d\d) сто[ $1] 2(\d\d) двісті[ $1] ([34])(\d\d) $1ста[ $2] (\d)(\d\d) $1сот[ $2] (1|\d?[02-9]1)(\d{3}) $(f:$1) тисяча[ $2] ([234]|\d?[02-9][234])(\d{3}) $(f:$1) тисячі[ $2] (\d{1,3})(\d{3}) $1| тисяч[ $2] (1|\d?[02-9]1)(\d{6}) $1 мільйон[ $2] ([234]|\d?[02-9][234])(\d{6}) $1 мільйона[ $2] (\d{1,3})(\d{6}) $1| мільйонів[ $2] (1|\d?[02-9]1)(\d{9}) $1 мільярд[ $2] ([234]|\d?[02-9][234])(\d{9}) $1 мільярда[ $2] (\d{1,3})(\d{9}) $1| мільярдів[ $2] (1|\d?[02-9]1)(\d{12}) $1 трильйон[ $2] ([234]|\d?[02-9][234])(\d{12}) $1 трильйона[ $2] (\d{1,3})(\d{12}) $1| трильйонів[ $2] (1|\d?[02-9]1)(\d{15}) $1 квадрильйон[ $2] ([234]|\d?[02-9][234])(\d{15}) $1 квадрильйона[ $2] (\d{1,3})(\d{15}) $1| квадрильйонів[ $2] (1|\d?[02-9]1)(\d{18}) $1 квінтильйон[ $2] ([234]|\d?[02-9][234])(\d{18}) $1 квінтильйона[ $2] (\d{1,3})(\d{18}) $1| квінтильйонів[ $2] (1|\d?[02-9]1)(\d{21}) $1 секстильйон[ $2] ([234]|\d?[02-9][234])(\d{21}) $1 секстильйона[ $2] (\d{1,3})(\d{21}) $1| секстильйонів[ $2] (1|\d?[02-9]1)(\d{24}) $1 септильйон[ $2] ([234]|\d?[02-9][234])(\d{24}) $1 септильйона[ $2] (\d{1,3})(\d{24}) $1| септильйонів[ $2] (1|\d?[02-9]1)(\d{27}) $1 октильйон[ $2] ([234]|\d?[02-9][234])(\d{27}) $1 октильйона[ $2] (\d{1,3})(\d{27}) $1| октильйонів[ $2] (1|\d?[02-9]1)(\d{30}) $1 нонільйон[ $2] ([234]|\d?[02-9][234])(\d{30}) $1 нонільйона[ $2] (\d{1,3})(\d{30}) $1| нонільйонів[ $2] (1|\d?[02-9]1)(\d{33}) $1 децильйон[ $2] ([234]|\d?[02-9][234])(\d{33}) $1 децильйона[ $2] (\d{1,3})(\d{33}) $1| децильйонів[ $2] (1|\d?[02-9]1)(\d{36}) $1 ундецильйон[ $2] ([234]|\d?[02-9][234])(\d{36}) $1 ундецильйона[ $2] (\d{1,3})(\d{36}) $1| ундецильйонів[ $2] (1|\d?[02-9]1)(\d{39}) $1 дуодецильйон[ $2] ([234]|\d?[02-9][234])(\d{39}) $1 дуодецильйона[ $2] (\d{1,3})(\d{39}) $1| дуодецильйонів[ $2] (1|\d?[02-9]1)(\d{42}) $1 тредецильйон[ $2] ([234]|\d?[02-9][234])(\d{42}) $1 тредецильйона[ $2] (\d{1,3})(\d{42}) $1| тредецильйонів[ $2] # negative numbers [-−]1 мінус один [-−](\d+) мінус |$1 # decimals "([-−]?)[.,](\d+)" $(\10.\2) "[-−]1[.,]" мінус одна ціла "([-−]?\d+[02-9]1|1)[.,]" $(f:|$1) ціла "([-−]?\d+)[.,]" $(f:|$1) цілих "([-−]?\d+[.,])1" $1| й одна десята "([-−]?\d+[.,])(\d)" $1| й $(f:|$2)| десятих "([-−]?\d+[.,])([02-9]1)" $1| й $(f:|$2) сота "([-−]?\d+[.,])(\d\d)" $1| й $(f:|$2)| сотих "([-−]?\d+[.,])(\d[02-9]1)" $1| й $(f:|$2) тисячна "([-−]?\d+[.,])(\d{3})" $1| й $(f:|$2)| тисячних "([-−]?\d+[.,])(\d)(\d)(\d)(\d)" $1| |$2 |$3 |$4 |$5 "([-−]?\d+[.,]\d*)(\d)" $1| |$2 # female conversion f:(.*)один \1одна f:(.*)два \1дві f:(.*) \1 # neuter conversion n:(.*)один \1одне n:(.*) \1 # possessive (1-999) - used in ordinals "pos:(.* )?од(ин|на) ?" [$(pos:\1)]одного "pos:(.* )?дв[аі] ?" [$(pos:\1)]двох "pos:(.* )?три ?" [$(pos:\1)]трьох "pos:(.* )?чотири ?" [$(pos:\1)]чотирьох "pos:(.* )?вісім ?" [$(pos:\1)]восьми "pos:(.* )?([а-я]+)ь ?" [$(pos:\1)]\2и "pos:(.* )?сорок ?" [$(pos:\1)]сорока "pos:(.* )?([а-я]+)десят ?" [$(pos:\1)]\2десяти "pos:(.* )?([а-я]*)сто ?" [$(pos:\1)]\2ста "pos:(.*)двісті ?" \1двохсот "pos:(.*)иста ?" \1ьохсот "pos:(.*)ісімсот ?" \1осьмисот "pos:(.*[^и])сот ?" \1исот pos:(.*) \1 # currency # unit/subunit us:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \1 up:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \2 ug:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \3 ss:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \4 sp:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \5 sg:([^,]*),([^,]*),([^,]*),([^,]*),([^,]*),([^,]*) \6 EUR:(\D+) $(\1: євро, євро, євро, цент, цента, центів) GBP:(\D+) $(\1: фунт стерлінгів, фунта стерлінгів, фунтів стерлінгів, пенні, пенса, пенсів) RUB:(\D+) $(\1: рубль, рубля, рублів, копійка, копійки, копійок) UAH:(\D+) $(\1: гривня, гривні, гривень, копійка, копійки, копійок) USD:(\D+) $(\1: долар США, долара США, доларів США, цент, цента, центів) "(UAH) ([-−]?1)([.,]00?)?" $(f:$2)|$(\1:us) "(UAH) ([-−]?\d*[02-9]1)([.,]00?)?" $(f:$2)|$(\1:us) "(UAH) ([-−]?[234])([.,]00?)?" $(f:$2)|$(\1:up) "(UAH) ([-−]?\d*[02-9][234])([.,]00?)?" $(f:$2)|$(\1:up) "(UAH) ([-−]?[0])([.,]0?)?" $2$(\1:ug) "(UAH) ([-−]?\d+)([.,]00?)?" $(f:$2)|$(\1:ug) "([A-Z]{3}) ([-−]?1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?\d*[02-9]1)([.,]00?)?" $2|$(\1:us) "([A-Z]{3}) ([-−]?[234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d*[02-9][234])([.,]00?)?" $2|$(\1:up) "([A-Z]{3}) ([-−]?\d+)([.,]00?)?" $2|$(\1:ug) "((RUB) [-−]?\d+)[.,]([02-9])1" $1 [$(\30) ]одна$(\2:ss) "((RUB) [-−]?\d+)[.,]([02-9])2" $1 [$(\30) ]двi$(\2:sp) "((UAH) [-−]?\d+)[.,]([02-9])1" $1 [$(\30) ]одна$(\2:ss) "((UAH) [-−]?\d+)[.,]([02-9])2" $1 [$(\30) ]двi$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](01)" $1 |$(1)$(\2:ss) "((EUR|GBP|USD) [-−]?\d+)[.,]([02-9]1)" $1 $3|$(\2:ss) "((EUR|GBP|USD) [-−]?\d+)[.,]([02-9]2)" $1 $3|$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,]([02-9][234])" $1 |$3$(\2:sp) "(([A-Z]{3}) [-−]?\d+)[.,](\d)" $1 |$(\30)$(\2:sg) "(([A-Z]{3}) [-−]?\d+)[.,](\d\d)" $1 |$3$(\2:sg) == cardinal(-masculine)? == ([-−]?[0-9]+) $2 == cardinal-feminine == 0 нуль ([-−]?[0-9]+) $(f:$1) == cardinal-neuter == 0 нуль ([-−]?[0-9]+) $(n:$1) == ordinal-feminine == 0 нульова ([-−]?\d+) $(ordinal-feminine |$1) (.*)один \1перша (.*)два \1друга (.*)три \1третя (.*)чотири \1четверта (.*)шість \1шоста (.*)ть \1та (.*)вісім \1восьма (.*)сім \1сьома (.*)к \1кова (.*)осто \1оста (.*)сто \1сота (.*)двісті \1двохсота (.*)иста \1ьохсота (.*)шістсот \2шестисота (.*)вісімсот \1восьмисота (.*)сімсот \2семисота (.*)сот \1исота "одна тисяча" тисячна "(.* )тисяч[аі]?" $(pos:\1)тисячна "один (\w+ль\w+)" \1на "(.* )([а-я]+ль[а-я]+)(а|ов)" $(pos:\1)\2на "(.* )([а-я]+ль[а-я]+)" $(pos:\1)\2на (.*) \1а == ordinal-neuter == ([-−]?\d+) $(ordinal-neuter |$(ordinal-feminine \1)) (.*)а \1е (.*)я \1є (.*) \1 == ordinal(-masculine)? == ([-−]?\d+) $(ordinal-masculine |$(ordinal-feminine \2)) (.*)а \2ий (.*)я \2ій (.*) \2 == ordinal-number-feminine == (\d+) \1-$(ordinal-number-neuter |$(ordinal-feminine \1)) == ordinal-number-neuter == (\d+) \1-$(ordinal-number-neuter |$(ordinal-neuter \1)) # use last two letters to get a consonant .*(..) \1 == ordinal-number(-masculine)? == (\d+) \2-й == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help cardinal-feminine)$(help cardinal-masculine)$(help cardinal-neuter)$(help ordinal-feminine)$(help ordinal-masculine)$(help ordinal-neuter)$(help ordinal-number-feminine)$(help ordinal-number-masculine)$(help ordinal-number-neuter)currency \(наприклад, UAH\): $(UAH 2.5) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
^0$ không 1 một 2 hai 3 ba 4 bốn ^5$ năm 5$ lăm 5 năm 6 sáu 7 bảy 8 tám 9 chín 1(\d) mười[ $1] (\d)0 $1 mươi (\d)1 $1 mươi mốt (\d)(\d) $1 mươi[ $2] (\d)01 $1 trăm linh một (\d)(\d\d) $1 trăm[ $2] (\d{1,3})000 $1 ngàn (\d{1,3})001 $1 ngàn không trăm linh một (\d{1,3})0(\d\d) $1 ngàn không trăm[ $2] (\d{1,3})(\d\d\d) $1 ngàn[ $2] (\d{1,3})0{6} $1 triệu (\d{1,3})0{5}1 $1 triệu không trăm linh một (\d{1,3})0{4}(\d\d) $1 triệu không trăm[ $2] (\d{1,3})(\d{6}) $1 triệu[ $2] (\d{1,10})0{9} $1 tỷ (\d{1,10})0{8}1 $1 tỷ không trăm linh một (\d{1,10})0{7}(\d\d) $1 tỷ không trăm[ $2] (\d{1,10})(\d{9}) $1 tỷ[ $2] == ordinal-number == (\d+) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help ordinal-number) (.*) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
# Mandarin Chinese number names (simplified) ^0 零 1 一 2 二 3 三 4 四 5 五 6 六 7 七 8 八 9 九 ^1(\d) 十$1 (\d)(\d) $1|十$2 (\d)0{2} $1百 (\d)0(\d) $1百零$2 (\d)(\d\d) $1百$2 (\d)0{3} $1千 (\d)0(\d\d) $1千零$2 (\d)(\d\d\d) $1千$2 (\d{1,4})0{4} $1|万 (\d{1,4})0(\d{3}) $1|万零$2 (\d{1,4})(\d{4}) $1|万$2 (\d{1,4})0{8} $1|亿 (\d{1,4})0(\d{7}) $1|亿零$2 (\d{1,4})(\d{8}) $1|亿$2 (\d{1,4})0{12} $1|兆 (\d{1,4})0(\d{11}) $1|兆零$2 (\d{1,4})(\d{12}) $1|兆$2 (\d{1,4})0{16} $1|京 (\d{1,4})0(\d{15}) $1|京零$2 (\d{1,4})(\d{16}) $1|京$2 (\d{1,4})0{20} $1|垓 (\d{1,4})0(\d{19}) $1|垓零$2 (\d{1,4})(\d{20}) $1|垓$2 (\d{1,4})0{24} $1|秭 (\d{1,4})0(\d{23}) $1|秭零$2 (\d{1,4})(\d{24}) $1|秭$2 (\d{1,4})0{28} $1|穰 (\d{1,4})0(\d{27}) $1|穰零$2 (\d{1,4})(\d{28}) $1|穰$2 (\d{1,4})0{32} $1|沟 (\d{1,4})0(\d{31}) $1|沟零$2 (\d{1,4})(\d{32}) $1|沟$2 (\d{1,4})0{36} $1|涧 (\d{1,4})0(\d{35}) $1|涧零$2 (\d{1,4})(\d{36}) $1|涧$2 (\d{1,4})0{40} $1|正 (\d{1,4})0(\d{39}) $1|正零$2 (\d{1,4})(\d{40}) $1|正$2 (\d{1,4})0{44} $1|载 (\d{1,4})0(\d{43}) $1|载零$2 (\d{1,4})(\d{44}) $1|载$2 # negative numbers [-−](\d+) 负|$1 # decimals "([-−]?\d+)[.,]" "$1|点" "([-−]?\d+[.,]\d*)(\d)" $1||$2 # currency # unit/subunit singular/plural AUD 澳元 CHF 瑞士法郎 CNY 人民币 EUR 欧元 GBP 英镑 HKD 港币 JPY 日圆 MOP 澳门元 USD 美元 # 1/10 角 # 1/100 分 "([A-Z]{3}) ([-−]?\d+([.,]\d+)?)" $2$1 # Mandarin Chinese number names, formal numbers (大写) for legal and financial documents, simplified == formal == ^0 零 1 壹 2$ 贰 2 贰 3 叁 4 肆 5 伍 6 陆 7 柒 8 捌 9 玖 ^1(\d) 拾$(formal \1) (\d)(\d) $(formal \1)|拾$(formal \2) (\d)0{2} $(formal \1)佰 (\d)0(\d) $(formal \1)佰零$(formal \2) (\d)(\d\d) $(formal \1)佰$(formal \2) (\d)0{3} $(formal \1)仟 (\d)0(\d\d) $(formal \1)仟零$(formal \2) (\d)(\d\d\d) $(formal \1)仟$(formal \2) (\d{1,4})0{4} $(formal \1)|万 (\d{1,4})0(\d{3}) $(formal \1)|万零$(formal \2) (\d{1,4})(\d{4}) $(formal \1)|万$(formal \2) (\d{1,4})0{8} $(formal \1)|亿 (\d{1,4})0(\d{7}) $(formal \1)|亿零$(formal \2) (\d{1,4})(\d{8}) $(formal \1)|亿$(formal \2) (\d{1,4})0{12} $(formal \1)|兆 (\d{1,4})0(\d{11}) $(formal \1)|兆零$(formal \2) (\d{1,4})(\d{12}) $(formal \1)|兆$(formal \2) (\d{1,4})0{16} $(formal \1)|京 (\d{1,4})0(\d{15}) $(formal \1)|京零$(formal \2) (\d{1,4})(\d{16}) $(formal \1)|京$(formal \2) (\d{1,4})0{20} $(formal \1)|垓 (\d{1,4})0(\d{19}) $(formal \1)|垓零$(formal \2) (\d{1,4})(\d{20}) $(formal \1)|垓$(formal \2) (\d{1,4})0{24} $(formal \1)|秭 (\d{1,4})0(\d{23}) $(formal \1)|秭零$(formal \2) (\d{1,4})(\d{24}) $(formal \1)|秭$(formal \2) (\d{1,4})0{28} $(formal \1)|穰 (\d{1,4})0(\d{27}) $(formal \1)|穰零$(formal \2) (\d{1,4})(\d{28}) $(formal \1)|穰$(formal \2) (\d{1,4})0{32} $(formal \1)|沟 (\d{1,4})0(\d{31}) $(formal \1)|沟零$(formal \2) (\d{1,4})(\d{32}) $(formal \1)|沟$(formal \2) (\d{1,4})0{36} $(formal \1)|涧 (\d{1,4})0(\d{35}) $(formal \1)|涧零$(formal \2) (\d{1,4})(\d{36}) $(formal \1)|涧$(formal \2) (\d{1,4})0{40} $(formal \1)|正 (\d{1,4})0(\d{39}) $(formal \1)|正零$(formal \2) (\d{1,4})(\d{40}) $(formal \1)|正$(formal \2) (\d{1,4})0{44} $(formal \1)|载 (\d{1,4})0(\d{43}) $(formal \1)|载零$(formal \2) (\d{1,4})(\d{44}) $(formal \1)|载$(formal \2) # negative numbers [-−](\d+) 负|$(formal \1) # decimals "([-−]?\d+)[.,]" "$(formal \1)|点" "([-−]?\d+[.,]\d*)(\d)" $(formal \1)||$(formal \2) # currency # unit/subunit singular/plural AUD 澳元 CHF 瑞士法郎 CNY 人民币 EUR 欧元 GBP 英镑 HKD 港币 JPY 日圆 MOP 澳门元 USD 美元 # 1/10 角 # 1/100 分 "([A-Z]{3}) ([-−]?\d+([.,]\d+)?)" $(formal \2)$(formal \1) == ordinal == ([-−]?\d+) 第$1 == ordinal-number == (.*) \1. == help == "" |$(1)|, |$(2)|, |$(3)|\n$(help formal)$(\0 ordinal)$(\0 ordinal-number) (formal|ordinal(-number)?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|\n
# Roman numbers 1:(.)(.)(.) \1 2:(.)(.)(.) \1\1 3:(.)(.)(.) \1\1\1 4:(.)(.)(.) \1\2 5:(.)(.)(.) \2 6:(.)(.)(.) \2\1 7:(.)(.)(.) \2\1\1 8:(.)(.)(.) \2\1\1\1 9:(.)(.)(.) \1\3 (\d) $(\1:IVX) (\d)(\d) $(\1:XLC)$2 (\d)(\d\d) $(\1:CDM)$2 ([123])(\d\d\d) $(\1:Mxx)$2 # [:Roman-large:] (\d+)(\d\d\d) \($1\)$2 # [:Roman-large:] ([123])(\d\d\d) $(\1:M--)$2 ([123]\d{3})(\d\d\d) $(overline $1)$2 # overline: ×1000 (\d{1,3})(\d\d\d) $(overline $1)$2 # overline: ×1000 ([123]\d{3})(\d{5}) \|$(overline $1)\|$2 # bar: ×100 (\d{1,3})(\d{5}) \|$(overline $1)\|$2 (\d+) \1 == overline == (.*)(.) $(overline \1)\2̅ # recursive overline == historical == (\d)(\d\d\d) $(\1:ↀↁↂ)$2 ([123])(\d\d\d\d) $(\1:ↂ--)$(historical \2) (.*) $1 == help == help Modules\nRoman-large (language code): multiple parenthesized form\nRoman: overline (×1000) with bar (×100)\nFunctions: historical – with special Unicode characters for 1000, 5000 and 10000
# Chinese Suzhou numbers, see Wikipedia (\d+)[.,](\d+) $(\1\2::)\n$(:\1:) (\d+) $(\1::)\n$(:\1:) (\d+)0:: $(\1::) (\d+):: $(\1:) 0: 〇 ^1: 〡 ^2: 〢 ^3: 〣 1: 一 2: 二 3: 三 4: 〤 5: 〥 6: 〦 7: 〧 8: 〨 9: 〩 :\d{2}: 拾 :\d{3}: 百 :\d{4}: 千 :\d{5}: 萬 :\d{6}: 拾萬 :\d{7}: 百萬 :\d{8}: 千萬 :\d{9}: 億 :\d{10}: 拾億 :\d{11}: 百億 :\d{12}: 千億 (\d+)0: $(\1:)〇 (\d+)0([1-9]\d*): $(\1:)〇|$(\2:) ^([123])(\d+): $(\1:)$(\2:) (\d)(\d+): $(\1:)|$(\2:) "\D\D\D (\d[.,\d]*)" $1元 # formal currency: 圆
# Old Hungarian script (ISO 15924 code: Hung) # Transliterate numbers and words # parentheses "([\(\[\{])(.*) 0$" \1$2 "(.*)([\]\)\}]) 0$" $1\2 # convert words with traditional or foreign "i" written as "y" # e.g. Áprily, Champs-Élysées, Élysée-palota, Dolly, Folly, Hollywood, jolly, intercity, Kisfaludy ... "^(Áp?ri?l|Champs-Él|[cC]i?t|Do?lák-Sa?l|[dfhjDFHJ]ol?l|Él|Fesz?t|[gG]rizz?l|Ha?rasz?t|Hat?va?n|Husz?t|[iI]n?ter?ci?t|Jé?ke?l|Kis?fa?lu?d|Ku?ko?r?el?l|Mo?ho?l|Mind?szen?t|Nosz?t|[pP]enn|Pes?t|Re?gu?l|So?n|Szi?l|Szte?va?no?vi?t|Vö?rös?mar?t|[zZ][lł]ot)y(.*) 0$" $1𐳐$2 "^(ÁP?RI?L|CHAMPS-ÉL|CI?T|DO?LÁK-SA?L|[DFHJ]OL?L|ÉL|FESZ?T|GRIZZ?L|HA?RASZ?T|HAT?VA?N|HUSZ?T|IN?TER?CI?T|JÉ?KE?L|KISFALU?D|KU?KO?R?EL?L|MIND?SZEN?T|MO?HO?L|NOSZ?T|PEN?N|PES?T|RE?GU?L|SO?N|SZI?L|SZTE?VA?NO?VI?T|VÖ?RÖS?MAR?T|Z[LŁ]OT)Y(.*) 0$" $1𐲐$2 # punctuation with transliterated letters "^((𐲀|𐲁|𐲂|𐲄|𐲆|𐲇|𐲉|𐲊|𐲋|𐲌|𐲍|𐲎|𐲏|𐲐|𐲑|𐲒|𐲓|𐲖|𐲗|𐲘|𐲙|𐲚|𐲛|𐲜|𐲞|𐲟|𐲠|𐲢|𐲤|𐲥|𐲦|𐲨|𐲪|𐲫|𐲬|𐲭|𐲮|𐲯|𐲰|𐳀|𐳁|𐳂|𐳄|𐳆|𐳇|𐳉|𐳊|𐳋|𐳌|𐳍|𐳎|𐳏|𐳐|𐳑|𐳒|𐳓|𐳖|𐳗|𐳘|𐳙|𐳚|𐳛|𐳜|𐳞|𐳟|𐳠|𐳢|𐳤|𐳥|𐳦|𐳨|𐳪|𐳫|𐳬|𐳭|𐳮|𐳯|𐳰|𐳺|𐳻|𐳼|𐳽|𐳾|𐳿|[-0-9–,„”.!\?\;‟⹂⹁⁏⸮])*[,„”\?\;]) 0$" $1 # if the original word contains an unknown character, return without modification "^(.*[^-0-9qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNMáäéëíóöőúüűÁÄÉËÍÓÖŐÚÜŰ–,„”\?\;].*) 0$" \1 # words with y "^y(ard.*) 0$" 𐳒$1 "^Y([aA][rR][dD].*|[uU]?[cC][oO][nN].*) 0$" 𐲒$1 "^Y([bB][lL].*) 0$" 𐲑$1 "^Y(vet?te.*) 0$" 𐲐$1 "^([bB]o|[cC]ow?bo|[dD]isp?la|[gG]ra|[pP]la)y(.*) 0$" $1𐳒$2 "^(BO|COW?BO|DISP?LA|GRA|PLA)Y(.*) 0$" $1𐲒$2 # don't transliterate other words with starting y "(^[yY].*) 0$" \1 # don't transliterate words with q, but not with qu "(^.*[qQ][^uU].*) 0$" \1 "(^.*[qQ]) 0$" \1 # other exceptions # Ágh -> Ág, Balogh -> Balog, Horváth -> Horvát, Mikszáth -> Mikszát, Németh -> Német, Tóth -> Tót, Virágh -> Virág, Végh -> Vég ^([Á][gG]|B[aA]?[lL][oO][gG]|H[oO][rR]?[vV][áÁ][tT]|M[iI][kK]?[sS][zZ][áÁ][tT]|N[éÉ]?[mM][eE][tT]|T[óÓ][tT]|V[iI]?[rR][áÁ][gG]|V[éÉ][gG])[hH](.*) $(\1\2) # Antall -> Antal, Gáll -> Gál, Széll -> Szél "^(An?tal|Gál|Szél)?l 0$" $(\1) "^(AN?TAL|GÁL|SZÉL)?L 0$" $(\1) # Apáthy -> Apáti, Bláthy -> Bláti, Básthy -> Básti ... ^(A?pá|Blá|Bás|Hon|Hor|Ka?rin|Kom?já|Szent?ku|Szom?ba)?thy(.*) $(\1ti\2) ^(A?PÁ|BLÁ|BÁS|HON|HOR|KA?RIN|KOM?JÁ|SZENT?KU|SZOM?BA)?THY(.*) $(\1TI\2) # Apponyi -> Aponyi ^Ap?([pP][oO]?[nN][yY][iI].*) $(A\1) # Babits -> Babics, Derkovits -> Derkovics, Takáts -> Takács, Szűts -> Szűcs ^(Ba?bi|Der?ko?vi|Sin?ko?vi|Ta?ká|Sz[üű])ts(.*) $(\1cs\2) ^(BA?BI|DER?KO?VI|SIN?KO?VI|TA?KÁ|SZ[ÜŰ])TS(.*) $(\1CS\2) # Bakách -> Bakács, Damjanich -> Damjanics, Forgách -> Forgács, Jurisich -> Jurisics, Madách -> Madács ^(Ba?ká|Dam?ja?ni|For?gá|Gras?sal?ko?vi|Ju?ri?si|Ma?dá)ch(.*) $(\1cs\2) ^(BA?KÁ|DAM?JA?NI|FOR?GÁ|GRAS?SAL?KO?VI|JU?RI?SI|MA?DÁ)CH(.*) $(\1CS\2) # Bakócz -> Bakóc, Börötz -> Böröc, Göncz -> Gönc, Makovecz -> Makovec, Móricz -> Móric ... ^(B[aA]?[kK][óÓ]|B[öÖ]?[rR][öÖ][cC]|G[öÖ][nN]|M[aA]?[kK][oO]?[vV][eE]|M[óÓ]?[rR][iI]|K[oO][nN]|O?[rR][aA]?[vV][eE]|R[áÁ]|R[áÁ]|T[iI]?[bB][oO][rR])([cCtT])[zZ](.*) $(\1\2\3) # Bakoss -> Bakos, Baross -> Baros, Boross -> Boros, Hankiss -> Hankis, Kass -> Kas, Kiss -> Kis, Terebess -> Terebes, Vass -> Vas "^(Ba?kos|Ba?ros|Bo?ros|Han?kis|Kas|Kis|Lo?vas|Te?re?bes|Vas)?s 0$" $(\1) "^(BA?KOS|BA?ROS|BO?ROS|HAN?KIS|KAS|KIS|LO?VAS|TE?RE?BES|VAS)?S 0$" $(\1) # Bay -> Baji "^Bay 0$" $(Baji) # Batsányi -> Bacsányi ^Ba?tsá?nyi(.*) $(Bacsányi) ^BA?TSÁ?NYI(.*) $(BACSÁNYI) # Bárczi -> Bárci, Kazinczy -> Kazinci, Rákóczi -> Rákóci ^(Bár|Ka?zin|Rá?kó)?cz[iy](.*) $(\1ci\2) ^(BÁR|KA?ZIN|RÁ?KÓ)?CZ[IY](.*) $(\1CI\2) # Báthory -> Bátori ^(B[áÁ]?[tT])[hH]([oO]?[rR][yY].*) $(\1\2) # Batthyány -> Battyányi ^Bat?thyá?ny(.*) $(Battyányi\1) ^BAT?THYÁ?NY(.*) $(BATTYÁNYI\1) # Bessenyei -> Besenyei ^(B[eE][sS])?[sS]([eE]?[nN][yY][eE]?[iI].*) $(\1\2) # Czuci -> Cuci, Czuczor -> Cucor ^Cz(u?c)z(([iI]|[oO][rR]).*) $(C\1\2) # Csathó -> Csató ^(C[sS][aA]?[tT])[hH]([óÓ].*) $(\1\2) # Dessewffy -> Dezsőfi ^De?s?sew?ffy(.*) $(Dezsőfi\1) ^DE?S?SEW?FFY(.*) $(DEZSŐFI\1) # Eördögh -> Ördög ^Eör?dögh(.*) $(Ördög\1) ^EÖR?DÖGH(.*) $(ÖRDÖG\1) # Eöry -> Őri, Eőry -> Őri ^E[öő]?ry(.*) $(Őri\1) ^E[ÖŐ]?RY(.*) $(ŐRI\1) # Eötvös -> Ötvös ^Eöt?vös(.*) $(Ötvös\1) ^EÖT?VÖS(.*) $(ÖTVÖS\1) # Gaál -> Gál ^Ga?ál(.*) $(Gál\1) # Háy -> Háji, Fáy -> Fáji, Márki-Zay -> Márki-Zaji, Vay -> Vaji ^(Há|Fá|Már?ki-?Za|Va|Za)y(.*) $(\1ji\2) ^(HÁ|FÁ|MÁR?KI-?ZA|VA|ZA)Y(.*) $(\1JI\2) # Joó -> Jó ^J[oO]?([óÓ].*) $(J\1) # Kéthly -> Kétli ^Kéth?ly(.*) $(Kétli\1) ^KÉTH?LY(.*) $(KÉTLI\1) # Konkoly-Thege -> Konkoli-Tege ^Kon?ko?ly-?The?g([eé].*) $(Konkoli-Teg\1) ^KON?KO?LY-?THE?G([EÉ].*) $(KONKOLI-TEG\1) # Koós -> Kós, Soós -> Sós ^([KS])[oO]([óÓ][sS])(.*) $(\1\2\3) # Kossuth -> Kosut, Passuth -> Pasut ^(K[oO]|P[aA])[sS]?([sS][uU][tT])[hH](.*) $(\1\2\3) # Pais -> Pajzs ^Pai?s(.*) $(Pajzs\1) ^PAI?S(.*) $(PAJZS\1) # Széchenyi -> Szécsényi ^Szé?che?nyi(.*) $(Szécsényi\1) ^SZÉ?CHE?NYI(.*) $(SZÉCSÉNYI\1) # Széchy -> Szécsi, Zichy -> Zicsi ^(Szé|Zi)?chy(.*) $(\1csi\2) ^(SZÉ|ZI)?CHY(.*) $(\1CSI\2) # Tarr -> Tar "^(T[aA][rR])[rR] 0$" $(\1) # Thewrewk -> Török ^Thew?rewk(.*) $(Török\1) ^THEW?REWK(.*) $(TÖRÖK\1) # Thököly -> Tököli ^Thö?kö?ly(.*) $(Tököli\1) ^THÖ?KÖ?LY(.*) $(TÖKÖLI\1) # Veér -> Vér ^V[eE]?([éÉ][rR].*) $(V\1) # Verseghy -> Versegi ^Ver?se?ghy(.*) $(Versegi\1) # Wass -> Vas "^Was?(sal|sá) 0$" $(Vas\1) "^WAS?(SAL|SÁ) 0$" $(VAS\1) ^Was?s(.*) $(Vas\1) ^WAS?S(.*) $(VAS\1) # Wesselényi -> Veselényi ^Wes?se?lé?nyi(.*) $(Veselényi\1) ^WES?SE?LÉ?NYI(.*) $(VESELÉNYI\1) # Weöres -> Vörös ^Weö?res(.*) $(Vörös\1) ^WEÖ?RES(.*) $(VÖRÖS\1) # Zigány -> Cigány ^Zi?gán(y|ny)(.*) $(Cigán\1\2) ^ZI?GÁN(Y|NY)(.*) $(CIGÁN\1\2) # avoid of exceeding recursion depth # convert by 200-character parts (.{200})(.+) $1$2 # numbers # remove space separated zero (in LibreOffice integration) "(\d+) 0" $1 "0: (.*) (.*)" "1: (.*) (.*)" \1 "2: (.*) (.*)" \1\1 "3: (.*) (.*)" \1\1\1 "4: (.*) (.*)" \1\1\1\1 "5: (.*) (.*)" \2 "6: (.*) (.*)" \2\1 "7: (.*) (.*)" \2\1\1 "8: (.*) (.*)" \2\1\1\1 "9: (.*) (.*)" \2\1\1\1\1 (\d) $(\1: 𐳺 𐳻) (\d)(\d) $(\1: 𐳼 𐳽)$2 1(\d\d) 𐳾$1 (\d)(\d\d) $1𐳾$2 1(\d\d\d)$ 𐳿$1 (\d{1,3})(\d\d\d) $1𐳿$2 1(\d{6})$ 𐳿𐳿$1 (\d{1,3})(\d{6}) $1𐳿𐳿$2 1(\d{9})$ 𐳿𐳿𐳿$1 (\d{1,3})(\d{9}) $1𐳿𐳿𐳿$2 # numbers with letters, for example dates with affixes "(\d+)([^ ]+)" $1$2 # letters "^(.*) 0$" $1 a(.*) 𐳀$1 A(.*) 𐲀$1 á(.*) 𐳁$1 Á(.*) 𐲁$1 b(.*) 𐳂$1 B(.*) 𐲂$1 ccs(.*) 𐳆𐳆$1 CCS(.*) 𐲆𐲆$1 cs(.*) 𐳆$1 C[sS](.*) 𐲆$1 c(.*) 𐳄$1 C(.*) 𐲄$1 d(.*) 𐳇$1 D(.*) 𐲇$1 e(.*) 𐳉$1 E(.*) 𐲉$1 é(.*) 𐳋$1 É(.*) 𐲋$1 ä(.*) 𐳋$1 Ä(.*) 𐲋$1 ë(.*) 𐳊$1 Ë(.*) 𐲊$1 f(.*) 𐳌$1 F(.*) 𐲌$1 ggy(.*) 𐳎𐳎$1 GGY(.*) 𐲎𐲎$1 gy(.*) 𐳎$1 G[yY](.*) 𐲎$1 g(.*) 𐳍$1 G(.*) 𐲍$1 h(.*) 𐳏$1 H(.*) 𐲏$1 i(.*) 𐳐$1 I(.*) 𐲐$1 í(.*) 𐳑$1 Í(.*) 𐲑$1 j(.*) 𐳒$1 J(.*) 𐲒$1 k(.*) 𐳓$1 K(.*) 𐲓$1 lly(.*) 𐳗𐳗$1 LLY(.*) 𐲗𐲗$1 ly(.*) 𐳗$1 L[yY](.*) 𐲗$1 l(.*) 𐳖$1 L(.*) 𐲖$1 m(.*) 𐳘$1 M(.*) 𐲘$1 nny(.*) 𐳚𐳚$1 NNY(.*) 𐲚𐲚$1 ny(.*) 𐳚$1 N[yY](.*) 𐲚$1 n(.*) 𐳙$1 N(.*) 𐲙$1 o(.*) 𐳛$1 O(.*) 𐲛$1 ó(.*) 𐳜$1 Ó(.*) 𐲜$1 ö(.*) 𐳞$1 Ö(.*) 𐲞$1 ő(.*) 𐳟$1 Ő(.*) 𐲟$1 p(.*) 𐳠$1 P(.*) 𐲠$1 qu(.*) 𐳓𐳮$1 # qu->kv Qu(.*) 𐲓𐳮$1 # Qu->Kv QU(.*) 𐲓𐲮$1 # QU->KV r(.*) 𐳢$1 R(.*) 𐲢$1 ssz(.*) 𐳥𐳥$1 SSZ(.*) 𐲥𐲥$1 sz(.*) 𐳥$1 S[zZ](.*) 𐲥$1 sch(.*) 𐳤$1 Sch(.*) 𐲤$1 s(.*) 𐳤$1 S(.*) 𐲤$1 tty(.*) 𐳨𐳨$1 TTY(.*) 𐲨𐲨$1 ty(.*) 𐳨$1 T[yY](.*) 𐲨$1 t(.*) 𐳦$1 T(.*) 𐲦$1 u(.*) 𐳪$1 U(.*) 𐲪$1 ú(.*) 𐳫$1 Ú(.*) 𐲫$1 ü(.*) 𐳭$1 Ü(.*) 𐲭$1 ű(.*) 𐳬$1 Ű(.*) 𐲬$1 [vw](.*) 𐳮$1 [VW](.*) 𐲮$1 x(.*) 𐳓𐳥$1 # x->ksz ^X 𐲓𐳥$1 # X->KSz X 𐲓𐲥$1 # X->KSZ X([A-ZÁÉËÍÓÖŐÚÜŰ].*) 𐲓𐲥$1 # X->KSZ X(.*) 𐲓𐳥$1 # X->Ksz y(.*) 𐳐$1 # .+y->i Y(.*) 𐲐$1 # .+Y->I zzs(.*) 𐳰𐳰$1 ZZS(.*) 𐲰𐲰$1 zs(.*) 𐳰$1 Z[sS](.*) 𐲰$1 z(.*) 𐳯$1 Z(.*) 𐲯$1 # remove ZWSP (used for consonant disambiguation) (.*) $1 # punctuation ”(.*) ‟$1 \;(.*) ⁏$1 \?(.*) ⸮$1 ,(.*) ⹁$1 „(.*) ⹂$1 # don't modify unknown characters (.)(.*) \1$2 (.*) \1
# numbering for multiple languages # note symbols # default: *, **, ***, ****, †, ‡, § # source: The United Nations Editorial Manual Online, access: 2022-07-14 # https://www.un.org/dgacm/en/content/editorial-manual/footnotes/chap-09 1 * 2 ** 3 *** 4 **** 5 † 6 ‡ 7 § (\d*) \1 # Note for LibreOffice users: adding ZWJ character before the return value # disables superscript only for that symbol in Writer. E.g. when asterisk is # already designed as a superscript letter, but the other symbols need manual # approximation of superscript character style: # #1 * #5 ** #9 *** # # In Writer, there are different numbering variants of the # following functions, (1) default, (2) superscript, except *, # (3) superscript, except *, †, ‡ (when the font contains also superscript # variants of † and ‡, and used by setting font feature "sups"). == chicago == # *, †, ‡, §, **, ††, ... # source: The Chicago Manual of Style Online access: 2022-07-14, # also used by LibreOffice Writer and OOXML (referred as "chicago") 1 * 2 † 3 ‡ 4 § 5 ** 6 †† 7 ‡‡ 8 §§ 9 *** 10 ††† 11 ‡‡‡ 12 §§§ 13 **** 14 †††† 15 ‡‡‡‡ 16 §§§§ 17 ***** 18 ††††† 19 ‡‡‡‡‡ 20 §§§§§ (\d*) \1 == chicago-table == # source: The Chicago Manual of Style Online access: 2022-07-14 # 3.79: Notes to specific parts of a table # https://www.chicagomanualofstyle.org/search.html?clause=dagger 1 * 2 † 3 ‡ 4 § 5 ‖ 6 \# 7 ** 8 †† 9 ‡‡ 10 §§ 11 ‖‖ 12 \#\# 13 *** 14 ††† 15 ‡‡‡ 16 §§§ 17 ‖‖‖ 18 \#\#\# (.*) \1 == bringhurst == # source: Bringhurst, R.: The Elements of Typographic Style, # implemented in footmisc – a portmanteau package for customizing # footnotes in LATEX, https://texdoc.org/serve/footmisc/0, access: 2022-07-14 1 * 2 † 3 ‡ 4 § 5 ‖ 6 ¶ 7 ** 8 †† 9 ‡‡ 10 §§ 11 ‖‖ 12 ¶¶ 13 *** 14 ††† 15 ‡‡‡ 16 §§§ 17 ‖‖‖ 18 ¶¶¶ (.*) \1 == gyurgyak == # source: J. Gyurgyák: Szerkesztők és szerzők kézikönyve, Osiris, 1997 # also used by Linux Libertine G font feature "foot" = 2 (default in Hungarian), # see http://numbertext.org/linux/fontfeatures.pdf 1 * 2 ** 3 *** 4 † 5 †† 6 ††† 7 ‡ 8 ‡‡ 9 ‡‡‡ 10 § 11 §§ 12 §§§ (.*) \1 == lamport == # source: footmisc – a portmanteau package for customizing footnotes in LATEX # https://texdoc.org/serve/footmisc/0, access: 2022-07-14 1 * 2 † 3 ‡ 4 § 5 ¶ 6 ‖ 7 ** 8 †† 9 ‡‡ 10 §§ 11 ¶¶ 12 ‖‖ 13 ** 14 †† 15 ‡‡ 16 §§ (.*) \1 == un == # source: The United Nations Editorial Manual Online, access: 2022-07-14 # https://www.un.org/dgacm/en/content/editorial-manual/footnotes/chap-09 # same as the default style (.*) $1 == wiley == # source: footmisc – a portmanteau package for customizing footnotes in LATEX # https://texdoc.org/serve/footmisc/0, access: 2022-07-14 1 * 2 ** 3 † 4 ‡ 5 § 6 ¶ 7 ‖ (.*) \1 == help == "" |$(1)|, |$(2)|, |$(3), |$(4), |$(5), |$(6), |$(7)|\n$(help chicago)$(help chicago-table)|$(help bringhurst)|$(help gyurgyak)|$(help lamport)|$(help un)|$(help wiley) (chicago-table) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|, $(\1 4)|, $(\1 5)|, $(\1 6)|\n ([-a-z]*?) \1: |$(\1 1)|, |$(\1 2)|, |$(\1 3)|, $(\1 4)|, $(\1 5)|, $(\1 6)|, $(\1 7)|\n