input: Write a function to perform a linear search through a given array. The function should return the position of the search item if found, otherwise return -1. If the array is empty, return -1.
  assert linearSearch('bookstore') == 2
  assert linearSearch('theatre') == 4
  assert linearSearch('library') == -1
  assert linearSearch('school') == 0
  assert linearSearch([]) == -1
output: def linearSearch(arr):
      if not arr:
          return -1
      for i in range(len(arr)):
          if arr[i] == 'o':
              return i
      return -1