From b3e39f01a5157137b8de7bf8fb07fcbcb7db2da0 Mon Sep 17 00:00:00 2001 From: sanyam jain <53706744+jssam@users.noreply.github.com> Date: Sat, 11 Sep 2021 03:51:15 +0530 Subject: [PATCH] parent node ==-1 than only we do changes bro, as per your video and algo thats is == the c++ code is right but there is bit mistake here --- articulationJava | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/articulationJava b/articulationJava index 9617d1e..02458fe 100644 --- a/articulationJava +++ b/articulationJava @@ -22,7 +22,7 @@ class Main low[node] = Math.min(low[node], tin[it]); } } - if(parent != -1 && child > 1) isArticulation[node] = 1; + if(parent == -1 && child > 1) isArticulation[node] = 1; } void printBridges(ArrayList> adj, int n) {