title: How to find if a given input is a meaningful word or not
body: <p>I am trying to solve a problem where i have given a text file with words followed by newline charecter</p>
  
  <p>I need to write a function which takes input as a string and should return output true if it is a meaningful word else false.</p>
  
  <p>My attempt of doing it is to traverse through the text file and maintain a hash for the words . If my given input is a word which exists in the hash i would return true else false.but hash has a space complexity of O(n) how else can we achieve this.</p>
  
  <p>Please help me with the solution.</p>