def get_terms(p):
    """
    This function gets the n-variable polynomial p and returns list of terms in this polynomial
    :param p: n-variable polynomial
    :return: list of terms which sum to polynomial p
    """
    return [m*c for m, c in zip(p.monomials(), p.coefficients())]