Get the name of a number, even if it's stupidly big.
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
|
- export type Scale = 'long' | 'short'
-
- export interface ConvertOptions {
- scale?: Scale
- }
-
- export interface StreamOptions {
- encoding?: BufferEncoding
- }
-
- type NumberDigit = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
-
- type StringDigit = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9'
-
- export type Digit = NumberDigit | StringDigit
-
- export type ReadStreamOptions = ConvertOptions & StreamOptions
-
- export type GetKiloCount = (hundreds: Digit, tens: Digit, ones: Digit) => string
- export type GetKiloName = (thousandPower: bigint) => string
- export type JoinKilo = (kiloCount: string, kiloName?: string) => string
-
- export interface NumberSystem {
- getKiloCount: GetKiloCount
- getKiloName: {
- short?: GetKiloName
- long?: GetKiloName
- europeanLong?: GetKiloName
- }
- joinKilo: JoinKilo
- }
-
- interface DigitString {
- [0]: string
- [1]: string
- [2]: string
- [3]: string
- [4]: string
- [5]: string
- [6]: string
- [7]: string
- [8]: string
- [9]: string
- ['0']: string
- ['1']: string
- ['2']: string
- ['3']: string
- ['4']: string
- ['5']: string
- ['6']: string
- ['7']: string
- ['8']: string
- ['9']: string
- }
-
- export interface NumberSystemNameTable {
- units: DigitString
- tenPlus: DigitString
- tenTimes: DigitString
- hundred: string
- thousand: string
- kiloSpecialUnits: DigitString
- kiloUnits: DigitString
- kiloTens: DigitString
- kiloHundreds: DigitString
- kiloThousand: string
- kiloEvenSuffix: string
- kiloOddSuffix: string
- and: string
- }
|