This problem can either be solved by the Kleitman–Wang algorithm or by the Fulkerson–Chen–Anstee theorem.
Această problemă poate fi rezolvată prin algoritmul Kleitman–Wang sau prin teorema Fulkerson–Chen–Anstee.