https://github.com/tableflip/scrabble-score
Map words to their scrabble score
https://github.com/tableflip/scrabble-score
Last synced: about 1 year ago
JSON representation
Map words to their scrabble score
- Host: GitHub
- URL: https://github.com/tableflip/scrabble-score
- Owner: tableflip
- License: isc
- Created: 2015-06-08T16:25:04.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2015-06-14T13:21:54.000Z (about 11 years ago)
- Last Synced: 2025-02-15T12:46:43.292Z (over 1 year ago)
- Language: JavaScript
- Size: 145 KB
- Stars: 2
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
Scrabble Score
==============
**Map words to their scrabble scores.**
Exports a single js function; takes a string, returns a number.
Case is unimportant, scrabble-score don't care.
Unknown characters are given a 0, `' ' => 0`, as does `'!?' => 0`.
**Example**
```js
var wordscore = require('../index.js')
var score = wordscore('tableflip')
console.assert(score === 16, "tableflip is worth 16 points")
```
Use `npm test` to run the tests.
Letter score data lovingly transcribed from google.com via: http://www.hasbro.com/scrabble/en_US/discover/faq.cfm