Nikolay Domashenko's submission of Hard Sequence | CodeChef