input: Write a python function to extract specified features from two lists based on given indices.
  assert extract_features(['a', 'b', 'c'], ['1', '2', '3'], [0, 2, 1]) == ['a', 'c', '2']
  assert extract_features(['x', 'y', 'z'], ['4', '5', '6'], [1, 0, 2]) == ['y', 'x', '6']
  assert extract_features(['p', 'q', 'r'], ['7', '8', '9'], [2, 1, 0]) == ['r', 'q', '7']
output: def extract_features(list1, list2, indices):
      result = []
      for index in indices:
          if index < len(list1):
              result.append(list1[index])
          else:
              result.append(list2[index - len(list1)])
      return result