We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 28addb1 commit 6e95083Copy full SHA for 6e95083
Cut Bridge or Cur Edges renamed to Cut Bridge or Cut Edges
@@ -23,12 +23,12 @@
23
System.out.println("Cut Edges / Cut Bridges are: ");
24
for (int i = 0; i < noOfVertices; i++) {
25
if (dfsnum[i] == 0) {
26
- cutVertices(adjMatrix,i,i);
+ cutEdges(adjMatrix,i,i);
27
}
28
29
30
31
- static void cutVertices(int[][] adjMatrix, int vertex,int pre){
+ static void cutEdges(int[][] adjMatrix, int vertex,int pre){
32
low[vertex]=dfsnum[vertex]=num++;
33
34
for(int v=0;v<noOfVertices;v++){
@@ -38,7 +38,7 @@
38
low[vertex]=Math.min(low[vertex],dfsnum[v]);
39
40
else{
41
- cutVertices(adjMatrix,v,vertex);
+ cutEdges(adjMatrix,v,vertex);
42
low[vertex] = Math.min(low[vertex],low[v]);
43
if(low[v]>dfsnum[vertex]){
44
System.out.println((char)('A'+vertex) +" ----- "+(char)('A'+v));
0 commit comments