Adjacency Matrix -> Directed graph -> DFS

Bitti

New Member
This is the code my friends and I have come up with so far after fiddling around. What we are trying to do is read in the adjacency matrix (input.txt), then create a directed graph out of it so we can search it using Depth-First Search. We want the output of our program to provide the order of visited nodes.The java code:http://pastebin.com/bAzBadxiThe input.txt file:http://pastebin.com/r72J34uAMy question is, what do we initialize "n" to? (line 32 in the java code)Any help will be appreciated.
 
Back
Top