Need Help in this question...

Revision en1, by CodingBeast23, 2020-10-13 18:59:46

You are given an array A of size N; find the minimum value of K such that number of subarrays with XOR value at most K is at least X:

  • 1 <=N << 10^5
  • 1 <= X <= N*(N+2)/2
  • 1 <= A[i] <= 10^6

    For Input :
    4 7
    1 2 3 4    
    Output : 4
    

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English CodingBeast23 2020-10-13 18:59:46 332 Initial revision (published)