Yet Another Problem On a Subsequence

CodeForces - 1000D