Check if Binary Array can be split into X Subarray with same bitwise XOR
Given a binary array A[] and an integer X, the task is to check whether it is possible to divide A[] into exactly X non-empty and non-overlapping subarrays such that each Ai belongs to exactly one subarray and the bitwise XOR of each subarray is the same. Examples: Input: A[] = {0, 1, 1, 0, 0}, X =