input: Write a python function to perform a linear search on a list to find the index of a target element.
  assert linear_search([1, 2, 3, 4, 5], 3) == 2
  assert linear_search([10, 20, 30, 40, 50], 25) == -1
  assert linear_search(['a', 'b', 'c', 'd'], 'd') == 3
output: def linear_search(lst, target):
      for index, element in enumerate(lst):
          if element == target:
              return index
      return -1