File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/main/java/com/thealgorithms/dynamicprogramming Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ public int getMaxMatching(int root, int parent) {
4141 if (root < 0 || root >= graph .size ()) {
4242 throw new IllegalArgumentException ("Invalid root: " + root );
4343 }
44- MaxMatching (root , parent );
44+ maxMatching (root , parent );
4545 return Math .max (dp [root ][0 ], dp [root ][1 ]);
4646 }
4747
@@ -52,7 +52,7 @@ public int getMaxMatching(int root, int parent) {
5252 * @param node The index of the current node for which the matching is calculated.
5353 * @param parent The index of the parent node (to avoid revisiting the parent node during recursion).
5454 */
55- private void MaxMatching (int node , int parent ) {
55+ private void maxMatching (int node , int parent ) {
5656 dp [node ][0 ] = 0 ;
5757 dp [node ][1 ] = 0 ;
5858
@@ -61,7 +61,7 @@ private void MaxMatching(int node, int parent) {
6161 if (adjNode == parent ) {
6262 continue ;
6363 }
64- MaxMatching (adjNode , node );
64+ maxMatching (adjNode , node );
6565 sumWithoutEdge += Math .max (dp [adjNode ][0 ], dp [adjNode ][1 ]);
6666 }
6767
You can’t perform that action at this time.
0 commit comments