Main adapted for the competition