simple realization basic algorithms used in natural language processing