Although I don't know any terms for this class of problem. Since XOR behaves slightly differently than addition, it is possible to break up the problem and make it solvable more easily than brute-force by focusing on one bit at a time.
Create a storage array at least the size of your bit-width; values will be stored in the array such that the n-th element (in a 1-indexed array) has the n-th bit as its most-significant bit (MSB). For each of the inputs (I'll refer to them ask masks), see if a value is stored with the same MSB set, and if so, XOR the values; this will clear out the MSB and result in a smaller number. Continue until no numbers stored have the same MSB set, then store the number. Numbers that result in a zero from this operation are redundant (eg with 13 and 5 stored, 8 is redundant since 8 = 13 xor 5).
Below is an implementation in Python 3 to see if it is possible to obtain a target given a number of masks. It does not currently report which of the input masks were used as the current version doesn't retain them. Try it on repl.it
def xor_combo(target, mask_list):
masks_by_bit = [0] * 8 # number of bits
# use defaultdict(int) for arbitrary size
for mask in mask_list:
# https://docs.python.org/3/library/stdtypes.html#int.bit_length
while masks_by_bit[mask.bit_length() - 1] != 0:
mask ^= masks_by_bit[mask.bit_length() - 1]
if mask != 0:
masks_by_bit[mask.bit_length() - 1] = mask
# else: redundant mask
while masks_by_bit[target.bit_length() - 1] != 0:
target ^= masks_by_bit[target.bit_length() - 1]
return (target == 0)
Example output:
xor_combo(5, [7, 2])
True : since 5 = 7 xor 2
xor_combo(5, [7, 3, 4])
False : since no combination 7, 3, and 4 can be combined via xor to give 5
xor_combo(5, [7, 3, 1])
True : since 5 = 7 xor 3 xor 1