https://github.com/nbaztec/bowling-score
https://github.com/nbaztec/bowling-score
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/nbaztec/bowling-score
- Owner: nbaztec
- Created: 2019-03-27T20:34:34.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-30T13:34:10.000Z (about 7 years ago)
- Last Synced: 2025-02-04T17:28:21.294Z (over 1 year ago)
- Language: JavaScript
- Size: 33.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# bowling-score
Given a list of throws in 10-pin bowling, returns the round score
Assumptions:
* number of throws are not validated
* computes score using standard 10-pin bowling rules for strike and spare
* no input validation for throws - assumes the input is comprised of numbers from 0-10
## Installation
* Requires Node `v10+`
```
$ npm i
$ npm test
```
## Usage
```
$ npm start 10 10 10 10 10 10 10 10 10 10 10 10
> bowling-score@1.0.0 start /home/nish/Documents/work/projects/bowling-score
> node index.js "10" "10" "10" "10" "10" "10" "10" "10" "10" "10" "10" "10"
300
```
or
```
$ node index.js 10 10 10 10 10 10 10 10 10 10 10 10
300
```