Determining the word types