Розбір
Subtask 1. Any subsequence of such a sequence is nondecreasing. Unfriendly sequences, however, do not allow equality of two adjacent elements, so any unfriendly subsequence of this sequence has to be strictly increasing. This means, that
Subtask 1. Any subsequence of such a sequence is nondecreasing. Unfriendly sequences, however, do not allow equality of two adjacent elements, so any unfriendly subsequence of this sequence has to be strictly increasing. This means, that