MININS - Editorial

@rishup_nitdgp Can you please explain this optimisation?

If we have, 2 2 as the array then we only need to replace anyone of the two with 1 but why answer is 2? Didn’t get this

https://www.codechef.com/viewsolution/38268741

can u point out where i am going wrong??