From cb1532bad23ec4374540ca539a05ae4e6ea37ddc Mon Sep 17 00:00:00 2001 From: aayushi-kunwar13 <51057675+aayushi-kunwar13@users.noreply.github.com> Date: Sun, 4 Oct 2020 03:00:08 +0530 Subject: [PATCH] Palindromic partitioning of a given string --- Palindromic Partitioning | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 Palindromic Partitioning diff --git a/Palindromic Partitioning b/Palindromic Partitioning new file mode 100644 index 0000000..c6dff84 --- /dev/null +++ b/Palindromic Partitioning @@ -0,0 +1,38 @@ +Return the minimum cuts needed for a palindrome partitioning of A. + +Example: +Input : A = "aab" +Output : 1 + + + +int Solution::minCut(string A) { + int n = A.length(), i, k, j; + int dp[n][n]; + int C[n]; + for(i=0; i