[코드포스 Practice10] B. Mislove Has Lost an Array
Mislove had an array a1, a2, ⋯, an of n positive integers, but he has lost it. He only remembers the following facts about it: The number of different numbers in the array is not less than l and is not greater than r; For each array's element ai either ai=1 or ai is even and there is a number ai2 in the array. For example, if n=5, l=2, r=3 then an array could be [1,2,2,4,4] or [1,1,1,1,2]; but i..
더보기