Created the main logic.