Worked on tokenize function