input: Write a python function to sort a dictionary by its values in ascending order.
  assert sort_dict_by_values({"a": 10, "b": 3, "c": 4, "d": 1, "e": 5}) == {"d": 1, "b": 3, "c": 4, "e": 5, "a": 10}
  assert sort_dict_by_values({"z": 2, "y": 1, "x": 3}) == {"y": 1, "z": 2, "x": 3}
  assert sort_dict_by_values({"apple": 50, "banana": 20, "cherry": 30}) == {"banana": 20, "cherry": 30, "apple": 50}
output: def sort_dict_by_values(d):
      return dict(sorted(d.items(), key=lambda item: item[1]))