follow logic and order rules