input: Write a function to classify text documents into two classes: positive and negative using Naive Bayes classification.
  
  def classify_text(text, positive_examples, negative_examples):
      import nltk
      from nltk.classify import NaiveBayesClassifier
      
      def label_words(words):
          return dict([(word, True) for word in words])
      
      positive_tokens = nltk.word_tokenize(positive_examples)
      negative_tokens = nltk.word_tokenize(negative_examples)
      
      positive_data = [(label_words(positive_tokens), 'positive')]
      negative_data = [(label_words(negative_tokens), 'negative')]
      
      train_data = positive_data + negative_data
      classifier = NaiveBayesClassifier.train(train_data)
      
      # classify
      return classifier.classify(label_words(nltk.word_tokenize(text)))
  
  assert classify_text("This movie was ok", "This is a great movie!", "This movie was terrible") == 'positive'
  assert classify_text("This movie was terrible", "This is a great movie!", "This movie was terrible") == 'negative'
  assert classify_text("This is a great movie!", "This is a great movie!", "This movie was terrible")== 'positive'
  assert classify_text("This movie was awful", "This is a great movie!", "This movie was terrible")== 'negative'
  assert classify_text("This was a good movie", "This is a great movie!", "This movie was terrible")== 'positive'
output: 
  def classify_text(text, positive_examples, negative_examples):
      import nltk
      from nltk.classify import NaiveBayesClassifier
      
      def label_words(words):
          return dict([(word, True) for word in words])
      
      positive_tokens = nltk.word_tokenize(positive_examples)
      negative_tokens = nltk.word_tokenize(negative_examples)
      
      positive_data = [(label_words(positive_tokens), 'positive')]
      negative_data = [(label_words(negative_tokens), 'negative')]
      
      train_data = positive_data + negative_data
      classifier = NaiveBayesClassifier.train(train_data)
      
      return classifier.classify(label_words(nltk.word_tokenize(text)))
  