input: Write a function to compute the average salary of people from a given CSV file named 'salary.csv'. The CSV file contains a header 'name, salary' and subsequent rows with names and corresponding salaries. If the CSV file is not provided or is empty, the function should return 0.
  
  assert get_average_salary('salary.csv') == 2000.0
  assert get_average_salary('empty_file.csv') == 0
  assert get_average_salary('no_such_file.csv') == 0
output: def get_average_salary(filename):
      try:
          with open(filename, 'r') as file:
              lines = file.readlines()[1:]
              if not lines:
                  return 0
              total_salary = sum(float(line.split(',')[1]) for line in lines)
              return total_salary / len(lines)
      except (FileNotFoundError, IndexError):
          return 0