Return the plural rule ('zero', 'one', 'two', 'few', 'many' or 'other') for a number and a locale.
Return the plural rule ('zero', 'one', 'two', 'few', 'many' or 'other') for a number and a locale.
Parameters
- $number
- The number to check the plural rule for for
- $locale
- The locale to use. If empty we'll use the default locale set in \Punic\Data
Returns
string
Returns one of the following values: 'zero', 'one', 'two', 'few', 'many', 'other'
Throws
Punic\Exception\BadArgumentType
Throws a \Punic\Exception\BadArgumentType if $number is not a valid number
Exception
Throws a \Exception if there were problems calculating the plural rule