Creation of Inverted index and query processing using python