input: Write a function to get the last n elements from a list.
  assert last_elements([1, 2, 3, 4, 5], 2) == [4, 5]
  assert last_elements([10, 20, 30, 40, 50], 3) == [30, 40, 50]
  assert last_elements(['a', 'b', 'c', 'd'], 1) == ['d']
output: def last_elements(lst, n):
      return lst[-n:]