Please help me to understand the logic

Please help me to understand the logic

Hey

  1. Maintain a boolean table[n][n] that is filled in bottom up manner.
  2. The value of table[i][j] is true, if the substring is palindrome, otherwise false.
  3. To calculate table[i][j], check the value of table[i+1][j-1], if the value is true and str[i] is same as str[j], then we make table[i][j] true.
  4. Otherwise, the value of table[i][j] is made false.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.