Moved compare smartly to right place