8 lines
181 B
TypeScript
8 lines
181 B
TypeScript
|
export const number_type = {
|
||
|
before: ['Complex'],
|
||
|
test: (n: unknown): n is number => typeof n === 'number',
|
||
|
from: {string: s => +s}
|
||
|
}
|
||
|
|
||
|
export const zero = (a: number) => 0
|