# Finding the number of different paths on a rectangular grid

• 03-14-2004
joejoefla
Finding the number of different paths on a rectangular grid
Attached is what my assignment is about that I'm kinda stuck on. The gist of the problem is I have to create a program that used a recursive function to find the number of different NE paths on a retangular grid. As in: There are 4 paths from (0,1) to (3,2)
(0,1) (0,2) (2,1) (2,2) (3,2)
(0,1) (1,1) (1,2) (2,2) (3,2)
(0,1) (1,1) (2,1) (2,2) (3,2)
(0,1) (1,1) (2,1) (3,1) (3,2):confused:

I can understand what a recursive func. is but it's going about how to do the program. W/O the recursive part I could probably figure it out. :?

I'm kinda new at C++. Thanks in advance.
• 03-14-2004
joejoefla
Here's the file.
• 03-14-2004
vasanth
Quote:

Originally posted by joejoefla
Here's the file.
Quote:

Originally posted by joejoefla
Here's the file.
Well the exit condition for the recursive function would be if the paths X axis exceeds the X axis of destination and same with Y... else just keep moving and increase the count...

Interesting.. will go home and code this...
:D but wont post the code for you to finish the home work :D:D... may be i will.. but i charge by the character..;)
• 03-14-2004
joejoefla
Hey thanks, I just been stuck in a runt for a while. You don't have to post the exact answer. I just need a kick in the right direction. ;)