def consistent(partial_solution, constraints, inconsistent_constraints):
    """Checks consistency of an assignment
    
    Parameters:
      partial_solution (dict) Represents partial assignment
      constraints (list) List of constraints
      inconsistent_constraints (list) List of constraints causing inconsistency 
    Returns:
      (boolean) True if an assignment is consistent, False otherwise
    """    
    for i, constraint in enumerate(constraints):
        try:
            if not eval(constraint, partial_solution):
                if i not in inconsistent_constraints:
                    inconsistent_constraints.append(i)
                return False
        except:
            pass
    return True