its giving 18 insted of 13 for a 3*3 board
Counting the mazepaths available with horizontal , vertical and diagonal moves
https://ide.codingblocks.com/s/229056 Alternate approach.
https://ide.codingblocks.com/s/229057 corrected code.
Keep this at the top:
if (sr > er || sc > ec) {
return 0;
}
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.