Codeforces Round #602 (Div. 2) D: Optimal Subsequences 权值线段树

NoSuchKey