You are given a string s and a character c.
Return the total number of substrings of s that start AND end with c.
A single character c at any position also counts as a valid substring (starts and ends with itself).
Input: Two comma-separated values: string s and character c.
Output: An integer — the count of substrings starting and ending with c.
Input: abada,a
Output: 6
Explanation: 'a' at indices 0,2,4 (count=3). Substrings: [0,0],[2,2],[4,4],[0,2],[0,4],[2,4] = 3+2+1 = 6 = 3*4//2.Input: aaaa,a
Output: 10
Explanation: 4 occurrences of 'a'. Answer = 4*5//2 = 10.Input: hello,z
Output: 0
Explanation: 'z' not in 'hello'.1 <= s.length <= 10^4s consists of lowercase English lettersc is a lowercase English letter