Time limit: 1s
Memory limit: 256MB
Input:
Output:
Task
You are given an integer and an integer . Display how many subsets of the set have the XOR sum equal to .
Input data
The first line contains two integers, and .
Output data
The first line will contain a single integer, the answer modulo .
Constraints and clarifications
- The XOR sum of the empty set is considered to be .
- For points, .
- For another points, .
Example 1
stdin
1 1
stdout
1
Example 2
stdin
3 0
stdout
2
Explanation
There are two subsets with the XOR sum of : and .