OR subarray

Revision en1, by temp1967, 2024-05-12 09:38:41

Given an array of size n and there are q queries with each query having a value. Want to find number of subarrays with or equal to the query value. 1<=n<=10^5; 1<=q<=10^5; A small hint I know was number of distinct or values in a subarray is 32*n; please prove it also.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English temp1967 2024-05-12 09:38:41 284 Initial revision (published)