It's impossible. The following is not a rigorous proof (rigorous proof of the lower bound is generally difficult), but reasonable reasoning.
Suppose your array always looks like 1, 2, 3, 4, 5, 6, ..., n. Then you are replacing a number of the appearance of the previous issue: 1, 2, 3, 3, 5, ... n. Now in the new array a[i] = ifor everyone i, except for one position.
, . , , , . , , one , .