Guest User

Untitled

a guest
Oct 20th, 2017
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. from nltk.tokenize import word_tokenize, sent_tokenize
  2.  
  3. text = "Hello, Mr. Jacobs. Nice to meet you!"
  4.  
  5. sentences = sent_tokenize(text)
  6. words = word_tokenize(text)
  7.  
  8. print (sentences)
  9. print (words)
Add Comment
Please, Sign In to add comment