writed all axioms via if
add check on axiom , it's better =)
working homework