Given a set
K = \{a_1, a_2, ..., a_n\}
S(K) is defined as
a_1 \oplus a_2 \oplus ... \oplus a_n
where oplus is the bitwise XOR. Given any set A, find a set B such that B is a subset of A and S(B) is maximized.
Given a set
S(K) is defined as
where oplus is the bitwise XOR. Given any set A, find a set B such that B is a subset of A and S(B) is maximized.