input: 
  Write a function called replace_word that takes a sentence, an old word, and a new word as arguments. The function should replace all occurrences of the old word in the sentence with the new word and return the updated sentence.
  
  assert replace_word("I love walking on the beach", "walking", "swimming") == "I love swimming on the beach"
  assert replace_word("Python is easy", "easy", "hard") == "Python is hard"
  assert replace_word("We are learning Python", "Python", "Java") == "We are learning Java"
  assert replace_word("I love Python", "Python", "Python") == "I love Python"
  assert replace_word("", "any", "none") == ""
  
output:     
      words = sentence.split()
      for i in range(len(words)):
          if words[i] == old_word:
              words[i] = new_word
      return ' '.join(words)
  