Palindromic Substrings
Given a string s, return the number of palindromic substrings in it. A string is a palindrome when it reads the same backward as forward.

30:00

Palindromic Substrings
medium
Topics
Companies

Given a string s, return the number of palindromic substrings in it. A string is a palindrome when it reads the same backward as forward.

Example 1:
Input: {"s":"abc"}
Output: 3
Constraints:
  • 1s.length10001 \leq s.\text{length} \leq 1000

  • s consists of lowercase English letters.

Input
arr ={"s":"abc"}

Start

a

b

c

Count:

0

Variables
No variables to display
DepthFunction Call
Stack empty
0/10