AdvancedRating 1600
Blocks With XOR k
Count the blocks of consecutive numbers whose XOR equals k.
Input
n and k, then n non-negative integers.
Output
One integer.
Sample 1
Input
5 6 4 2 2 6 4
Output
4
Sample 2
Input
5 5 5 6 7 8 9
Output
2
Output appears here