Codeforces Round #638 (Div. 2) F. Phoenix and Memory 区间贪心+线段树

NoSuchKey