Add isWord method