public function addWord($word, $value = 1)
    {
        if (isset($this->wordsArray[$word])) {
            $this->wordsArray[$word] += $value;
        } else {
            $this->wordsArray[$word] = $value;
        }
    }
public function addWord($word, $value = 1)
    {
        if (isset($this->wordsArray[$word])) {
            $this->wordsArray[$word] += $value;
        } else {
            $this->wordsArray[$word] = $value;
        }
    }
public function addWord ( $ word , $ value = 1 ) { if ( isset ( $ this -> wordsArray [ $ word ] ) ) { $ this -> wordsArray [ $ word ] += $ value ; } else { $ this -> wordsArray [ $ word ] = $ value ; } }
Assign word to array
@param string $word
@param int $value
@return string
Assign word to array