input: 
  from typing import List
  
  def detect_expansion_loop_error(funcs: List[str]) -> List[str]:
      """
      Given a list of function definitions as strings, detect and return the names of functions that potentially have an error
      where a list is being modified while iterating over it.
      
      >>> detect_expansion_loop_error(["def expand_list(list):\n    for item in list:\n        list *= 2"])
      ['expand_list']
      >>> detect_expansion_loop_error(["def another_func(list):\n    for item in list:\n        list.append(item)"])
      ['another_func']
      """
  
output:     error_funcs = []
      for func in funcs:
          if "for " in func and (" *= " in func or ".append(" in func or ".extend(" in func or ".insert(" in func):
              func_name = func.split("def ")[1].split("(")[0]
              error_funcs.append(func_name)
      return error_funcs