human
Solve the following python programming problem given the following code:
@public
def lcm_list(seq, *gens, **args):
assistant
#Here is the Python code you requested.

    """Compute LCM of a list of polynomials.
    Examples
    >>> from sympy import lcm_list
    >>> from sympy.abc import x
    >>> lcm_list([x**3 - 1, x**2 - 1, x**2 - 3*x + 2])
    x**5 - x**4 - 2*x**3 - x**2 + x + 2
    """
    seq = sympify(seq)
    def try_non_polynomial_lcm(seq):
        if ((not gens) and (not args)):
            (domain, numbers) = construct_domain(seq)
            if (not numbers):
                return domain.one
            elif domain.is_Numerical:
                (result, numbers) = (numbers[0], numbers[1:])
                for number in numbers:
                    result = domain.lcm(result, number)
                return domain.to_sympy(result)
        return None
    result = try_non_polynomial_lcm(seq)
    if (result is not None):
        return result
    options.allowed_flags(args, ['polys'])
    try:
        (polys, opt) = parallel_poly_from_expr(seq, *gens, **args)
    except PolificationFailed as exc:
        result = try_non_polynomial_lcm(exc.exprs)
        if (result is not None):
            return result
        else:
            raise ComputationFailed('lcm_list', len(seq), exc)
    if (not polys):
        if (not opt.polys):
            return S.One
        else:
            return Poly(1, opt=opt)
    (result, polys) = (polys[0], polys[1:])
    for poly in polys:
        result = result.lcm(poly)
    if (not opt.polys):
        return result.as_expr()
    else:
        return result