ROUTE-COUNT(G)
DFS(G)
count = 0
return COUNT(G,s,t)
COUNT(G,s,t)
for each v in G:Adj[s]
if v.d == t.d
count = count + 1
else if v.d <t.d
return count + COUNT(G,v,t)
return count
ROUTE-COUNT(G)
DFS(G)
count = 0
return COUNT(G,s,t)
COUNT(G,s,t)
for each v in G:Adj[s]
if v.d == t.d
count = count + 1
else if v.d <t.d
return count + COUNT(G,v,t)
return count