input: Write a function to compute the sum of all values in a given dictionary (string → integer). If the dictionary is empty or the values are invalid then return 0.
  compute_dict_sum({
     "a": 5,
     "b": 10,
     "c": 15
  })==30
  compute_dict_sum({
     "x": 2,
     "y": 3,
     "z": 4
  })==9
  compute_dict_sum({})==0
  compute_dict_sum({
     "p": 0,
     "q": 0,
     "r": 0
  })==0
  compute_dict_sum({
     "m": -1,
     "n": 1,
     "o": 0
  })==0
output: def compute_dict_sum(d):
      if not d:
          return 0
      try:
          return sum(d.values())
      except TypeError:
          return 0