input: Write a python function to merge two dictionaries by taking the union of their keys, and for overlapping keys, use the value from the first dictionary.
  assert merge_dicts({'a': 1, 'b': 2}, {'b': 3, 'c': 4}) == {'a': 1, 'b': 2, 'c': 4}
  assert merge_dicts({'x': 10, 'y': 20}, {'y': 30, 'z': 40}) == {'x': 10, 'y': 20, 'z': 40}
  assert merge_dicts({'k1': 'v1'}, {'k2': 'v2'}) == {'k1': 'v1', 'k2': 'v2'}
output: def merge_dicts(dict1, dict2):
      merged_dict = dict2.copy()
      merged_dict.update(dict1)
      return merged_dict