All submissions for this problem are available.
An n digit number, N, is called good if:
None of its digits is a 0,
If you write the digits as d_1, d_2, d_3, ..., d_n then d_i is a multiple of ((i - 1) modulo 3) + 1 and
N is a multiple of 2 ^ a and b.
How many good n digit numbers are there for a given n, a and b?
Single line containing 3 space separated integers - n, a and b..
Output a single integer, the answer modulo 1,000,000,007.
1 <= n <= 100,000,000, 0 <= a <= 8 and 1 <= b <= 50.
Input: 2 2 3 Output: 7
|Time Limit:||5 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.5, PYPY|
Fetching successful submissions
If you are still having problems, see a sample solution here.