Can you explain more about this problem briefly?
What will be the output for input 8 4?
Print answer for every test case in a new line modulo 10^9 + 7 What does this means?
Can you explain more about this problem briefly?
What will be the output for input 8 4?
Print answer for every test case in a new line modulo 10^9 + 7 What does this means?
For n=8 and m = 4,
What are possibilities to put the 1x4 tile, either put it horizontally then we left with (n-1) i.e 7 rows and if we placed vertically then we left with (n-m) rows i.e 4.
The answer will be computed recursively.
Make a grid in the notebook and you will get the logic.
Since the number of ways can be very large which will overflow the integer value in that’s why we take the modulus of the answer with a prime i.e 10^9 + 7, to reduce the answer below 10^9 + 7.
can you please tell the exact answer for a 3*2 floor ( i.e n = 3 and m = 2).
the reason why I’m asking this is because I want to see if permutation and combination of sequence in which tiles are laid also matters.
You can see the solution and can make P and C to work.
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.