I'm stuck in this problem: https://quera.org/problemset/34090?tab=description
you can use google translation for the statement
For n ≤ 22, I used brute force. For n ≥ 40, I randomly selected two disjoint subsets of size 18, and it worked fine. However, I'm failing the cases where 22 < n < 40.
Here is a code snippet: https://pastecode.io/s/h6rdjqzf
the cases I'm failing have 24 < n < 40 Previously, I tried selecting 18 random elements for set1, then chose elements not in set1 for set2, and filled the rest randomly without repetition.
This also failed — the cases where 24 < n < 40 are particularly tough. It's as if there's only one unique solution, and the problem expects you to find it through randomness.



