input: Write a function to return the sum of the items in a given list. If the list is empty, return 0.
  assert sum_list([1, 2, 3, 4, 5]) == 15
  assert sum_list([7, 8, 9]) == 24
  assert sum_list([]) == 0
output: def sum_list(lst):
      return sum(lst) if lst else 0