https://github.com/chantastic/circum
A positive array index for any number.
https://github.com/chantastic/circum
Last synced: about 1 year ago
JSON representation
A positive array index for any number.
- Host: GitHub
- URL: https://github.com/chantastic/circum
- Owner: chantastic
- License: mit
- Created: 2017-01-04T23:03:04.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-01-04T23:08:22.000Z (over 9 years ago)
- Last Synced: 2025-02-27T03:02:10.838Z (over 1 year ago)
- Language: JavaScript
- Size: 2.93 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# circum [](https://travis-ci.org/chantastic/circum)
> An array index for any number.
## Install
```
$ npm install --save circum
```
## Usage
```js
const circum = require('circum');
circum([1,2,3], -2);
//=> 1
```
## API
### circum(arr, index)
#### arr
Type: `array`
#### index
Type: `number`
## License
MIT © [Michael Chan](http://chantastic.org)