Skip to content

Commit 0cfc178

Browse files
author
Raghav Dua
committed
removed argument from _wait ()
1 parent d104334 commit 0cfc178

File tree

1 file changed

+5
-5
lines changed
  • algorithm/graph_search/bridges/naive

1 file changed

+5
-5
lines changed

algorithm/graph_search/bridges/naive/code.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ function DFSExplore (graph, source) {
1313
//logger._print (node);
1414

1515
/*
16-
if (prev !== undefined && graph [node] [prev]) { tracer._visit (node, prev)._wait (200); console.log ('tracer ' + prev + ', ' + node); }
17-
else { tracer._visit (node)._wait (200); console.log ('tracer ' + node); }
16+
if (prev !== undefined && graph [node] [prev]) { tracer._visit (node, prev)._wait (); console.log ('tracer ' + prev + ', ' + node); }
17+
else { tracer._visit (node)._wait (); console.log ('tracer ' + node); }
1818
*/
1919

2020
for (i = 0; i < graph.length; i++) {
@@ -35,8 +35,8 @@ function findBridges (graph) {
3535
for (var j = 0; j < graph.length; j++) {
3636
if (graph [i] [j]) { //check if an edge exists
3737
logger._print ('Deleting edge ' + i + '->' + j + ' and calling DFSExplore ()');
38-
tracer._visit (j, i)._wait (200);
39-
tracer._leave (j, i)._wait (200);
38+
tracer._visit (j, i)._wait ();
39+
tracer._leave (j, i)._wait ();
4040

4141
tempGraph = JSON.parse (JSON.stringify (graph));
4242
tempGraph [i] [j] = 0;
@@ -63,4 +63,4 @@ logger._print ('The bridges are: ');
6363
for (var i in bridges) {
6464
logger._print (bridges [i] [0] + ' to ' + bridges [i] [1]);
6565
}
66-
logger._print ('NOTE: A bridge is both ways, i.e., from A to B and from B to A, because this is an Undirected Graph');
66+
logger._print ('NOTE: A bridge is both ways, i.e., from A to B and from B to A, because this is an Undirected Graph');

0 commit comments

Comments
 (0)