def monomial_div(A, B):
 C = monomial_ldiv(A, B)
 if all(((c >= 0) for c in C)):
  return tuple(C)
 else:
  return None

def monomial_div ( A , B ) : C = monomial_ldiv ( A , B ) if all ( ( ( c >= 0 ) for c in C ) ) : return tuple ( C ) else : return None
division of tuples representing monomials .