I'm working on a java assignment for a class and I'm unsure how to solve this problem. I don't want it completed for me, but get me started in the right direction. I'm mostly unsure of the recursive part of the program. I'm not very good at programming.
problem:
NorthEast paths are obtained from a two-dimensional grid by moving up and right. For example, in the figure below, there are two paths from 1,0 to 0,1. The first is (1,0), (0,0), (0,1), the second is (1,0), (1,1), (0,1). Note that there are no NorthEast paths from (0,1) to any other point. Also note that there is one NorthEast path from (1,1) to (0,1). You are to write a program that takes a number (size of grid - no larger than 10) and a starting location and an ending location and recursively computes all of the "NorthEast" paths.
0,0 0,1
1,0 1,1
I'm reading in the file prog2.dat
which reads in the grid size first and then the starting coordinates and then finishing coordinates. for example:
5
3 0
1 3
It needs to be one files, so I'm going to use methods. If someone could get me started or direct me to a similar question already posted, I would appreciate it.