input: Write a python function to detect plagiarism between two texts.
  assert detect_plagiarism('This is an example of text I just made up.', 'This is an example of text I wrote.') == 0.5
  assert detect_plagiarism('The quick brown fox jumps over the lazy dog.', 'The quick brown fox jumps over the lazy dog.') == 1.0
  assert detect_plagiarism('Hello world!', 'Goodbye world!') == 0.3333333333333333
  assert detect_plagiarism('Python is great.', 'Python is awesome.') == 0.4
output: def detect_plagiarism(text1, text2):
      words1 = set(text1.split())
      words2 = set(text2.split())
      intersection = words1.intersection(words2)
      union = words1.union(words2)
      return len(intersection) / len(union)