https://github.com/semibran/catalan
Calculate Catalan numbers
https://github.com/semibran/catalan
Last synced: 8 months ago
JSON representation
Calculate Catalan numbers
- Host: GitHub
- URL: https://github.com/semibran/catalan
- Owner: semibran
- License: mit
- Created: 2017-06-27T19:46:01.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-06-27T19:49:06.000Z (almost 9 years ago)
- Last Synced: 2025-03-16T11:45:54.961Z (over 1 year ago)
- Language: JavaScript
- Size: 1000 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# catalan

A small function for calculating [Catalan numbers](https://en.wikipedia.org/wiki/Catalan_number).
## usage
[](https://www.npmjs.com/package/catalan)
```js
> const catalan = require('catalan')
> catalan(5)
42
> catalan(-1)
NaN
```
## see also
- [`semibran/narayana`](https://github.com/semibran/narayana) - calculate Narayana numbers
## license
[MIT](https://opensource.org/licenses/MIT) © [Brandon Semilla](https://git.io/semibran)