input: Write a python function to find the first occurrence of a substring within a string.
  assert find_first_occurrence("This is just a sample string to test out search within a string program", "within") == 39
  assert find_first_occurrence("hello world", "world") == 6
  assert find_first_occurrence("test case", "case") == 5
  assert find_first_occurrence("python coding", "java") == -1
output: def find_first_occurrence(main_string, substring):
      try:
          return main_string.index(substring)
      except ValueError:
          return -1