Initial attempt at javascript scrabble score