If you're asking how I constructed the counterexample array start with 8 as the starting number you can flatten the arrays into 4 4 then 2 2 2 2 and for the second into 4 4 then 2 2 4 then 1 1 1 1 4 and concatenate them.
If you're asking about the solution, you can check the official solution in the editorial, it's quite interesting!
If you're asking how I constructed the counterexample array start with 8 as the starting number you can flatten the arrays into 4 4 then 2 2 2 2 and for the second into 4 4 then 2 2 4 then 1 1 1 1 4 and concatenate them.
If you're asking about the solution, you can check the official solution in the editorial, it's quite interesting!