Establishing the basic execution loop