## Number of sub-strings that contain the given character exactly k times

Given a string str, a character c and an integer k > 0. The task is to find the number of sub-strings that contain the… Read More »

- Count substrings that contain all vowels | SET 2
- Minimum number of times A has to be repeated such that B is a substring of it
- Largest substring with same Characters
- Count of substrings which contains a given character K times
- Maximum length palindromic substring such that it starts and ends with given char
- Find distinct characters in distinct substrings of a string
- Maximum number of given operations to remove the entire string
- Queries to find the first non-repeating character in the sub-string of a string
- Maximum String Partition
- Number of substrings that start with "geeks" and end with "for"
- Number of balanced parenthesis substrings
- Count number of substrings of a string consisting of same characters
- Count all substrings having character K
- Count of non-overlapping sub-strings "101" and "010" in the given binary string
- Frequency of a substring in a string using pthread
- Longest sub string of 0's in a binary string which is repeated K times
- Minimum number of substrings the given string can be splitted into that satisfy the given conditions
- Check if string can be rearranged so that every Odd length Substring is Palindrome
- Reverse the given string in the range [L, R]
- Repeat substrings of the given String required number of times
- Count number of binary strings such that there is no substring of length greater than or equal to 3 with all 1's
- Largest substring of str2 which is a prefix of str1
- Longest substring such that no three consecutive characters are same
- Largest sub-string where all the characters appear at least K times
- Contiguous unique substrings with the given length L
- Find the longest sub-string which is prefix, suffix and also present inside the string | Set 2

Given a string str, a character c and an integer k > 0. The task is to find the number of sub-strings that contain the… Read More »

Given a string str and a character X. The task is to find the total number of sub-strings that contain the character X at least… Read More »

Given an integer N, the task is to find the length of the longest substring containing only 4’s from the first N characters of the… Read More »

Given a string str consisting of lowercase English letters and an integer K. The task is to find the minimum length of the sub-string whose… Read More »

Given a string str and an integer N, the task is to find the number of possible sub-strings of length N. Examples: Input: str =… Read More »

Given a string str and a character c. The task is to find the number of sub-strings that do not consist of the character c.… Read More »

Given a string S. The task is to count the non-overlapping pairs of palindromic sub-strings S1 and S2 such that the strings should be S1[L1…R1]… Read More »

Given a string str, the task is to find the length of the longest sub-string which does not have any pair of consecutive same characters.… Read More »

Given a string str, the task is to find the count of all the sub-strings of length four whose characters can be rearranged to form… Read More »

Given an integer N, the task is to generate all possible binary strings of length N which contain “01” as the sub-string exactly twice. Examples:… Read More »

Given a string str consisting only of the characters ‘a’, ‘b’ and ‘c’, find the number of sub-strings that do not contain all the three… Read More »

Given a string S and a range [L, R]. The task is to find the number of ways in which the sub-string in the range… Read More »

Every state is represented by string of length 2. For example DL is used for Delhi, HP for Himachal Pradesh, UP for Uttar Pradesh, PB… Read More »

Given a string str and an integer K, the task is to check whether the given string is K-periodic. A string is k-periodic if the… Read More »

Given a string S and a number K. The task is to find the minimum length substring having exactly K distinct characters. Note: The string… Read More »