python - How to check if sentence contains words only from a file -


i trying create program checks if string entered user contains words text file, contain words english dictionary. remove slang language. if have other way of doing this, please let me know relatively new python. in advance.

  1. take dictionary, put words in sort of hash set.
  2. take sentence, split words, hash each word. check if hash occurs in hash set.

Comments

Popular posts from this blog

java - pagination of xlsx file to XSSFworkbook using apache POI -

Unlimited choices in BASH case statement -

apache - How do I stop my index.php being run twice for every user -