polycarp create training plan prepare programming contest he train n day day number 1 n begin firstOn ith day Polycarp necessarily solve a_i problem one evening Polycarp plan celebrate equator he celebrate evening day begin training day inclusive solve half problemsdetermine index day Polycarp celebrate equator