Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/writetome51/is-odd-is-even
isOdd(num) and isEven(num)
https://github.com/writetome51/is-odd-is-even
even javascript numbers odd odd-even typescript
Last synced: 12 days ago
JSON representation
isOdd(num) and isEven(num)
- Host: GitHub
- URL: https://github.com/writetome51/is-odd-is-even
- Owner: writetome51
- License: mit
- Created: 2018-10-14T22:26:21.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-07-28T06:08:35.000Z (over 4 years ago)
- Last Synced: 2024-11-07T01:09:31.776Z (14 days ago)
- Topics: even, javascript, numbers, odd, odd-even, typescript
- Language: JavaScript
- Homepage:
- Size: 15.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# isOdd(integer): boolean
# isEven(integer): boolean## Examples
```
isOdd(2); // --> falseisEven(2); // --> true
isEven(2.2); // --> 'Error: input must be integer'
isEven('2'); // --> 'Error: input must be finite number of type "number"'
```## Installation
`npm i @writetome51/is-odd-is-even`## Loading
```js
import { isOdd, isEven} from '@writetome51/is-odd-is-even';
```