The question is asking for all the committees which can be formed, but the condition is that if B is included, A must be excluded. The group can have neither A nor B, just A or just B
Therefore, your solution is the total combinations, 10C6, minus all combinations where A and B are together...