## Maximum length palindromic substring such that it starts and ends with given char

Given a string str and a character ch, the task is to find the longest palindromic sub-string of str such that it starts and ends… Read More »

- Make all numbers of an array equal
- Optimal Strategy for a Game | Set 2
- Sliding Window Maximum (Maximum of all subarrays of size k) using stack in O(n) time
- Sum of XOR of all subarrays
- Find k closest numbers in an unsorted array
- Count pairs in array whose sum is divisible by K
- Building Heap from Array
- Amazon Internship Interview Experience
- Program for K Most Recently Used (MRU) Apps
- Merge K sorted arrays | Set 3 ( Using Divide and Conquer Approach )
- Longest subsequence such that adjacent elements have at least one common digit
- k-th missing element in an unsorted array
- Minimum operations required to make all the array elements equal
- Count of pairs (x, y) in an array such that x < y
- Maximum sum such that no two elements are adjacent | Set 2
- Number of unique pairs in an array
- Check if given Preorder, Inorder and Postorder traversals are of same tree | Set 2
- Merge K sorted arrays of different sizes | ( Divide and Conquer Approach )
- Maximum element in a sorted and rotated array
- Length of the longest alternating subarray
- Minimum elements to be removed such that sum of adjacent elements is always even
- Given two arrays count all pairs whose sum is an odd number
- Array Manipulation and Sum
- Remove minimum elements from either side such that 2*min becomes more than max | Set 2
- Sort an array without changing position of negative numbers
- Count array elements that divide the sum of all other elements
- Create linked list from a given array
- Find minimum difference between any two elements | Set 2
- Find two numbers whose divisors are given in a random order
- Maximum absolute difference in an array

Given a string str and a character ch, the task is to find the longest palindromic sub-string of str such that it starts and ends… Read More »

Given an array arr[] of size N and an integer K which means there are N piles of coins and the ith contains arr[i] coins.… Read More »

Given an array arr[] of N non-negative integers. The task is to find the length of the longest sub-array such that XOR of all the… Read More »

Given an array arr[] of N integers, the task is to check if it is possible to redistribute the array such that for every 1… Read More »

Given two arrays a[] and b[], the task is to find the count of all pairs (a[i], b[j]) such that a[i] + b[j] is unique… Read More »

Given an array arr[] of length N ≥ 2. The task is to remove an element from the given array such that the GCD of… Read More »

Given two arrays A[] and B[] which consists of N and M strings respectively. A string S1 is said to be smaller than string S2… Read More »

Given an array arr[] of integers and an integer K, the task is to find the greatest contiguous sub-array of size K. Sub-array X is… Read More »

Given two integers N and K where N, K > 0, the task is to find the total number of pairs (a, b) where 1… Read More »

Given an array arr[] of N elements, the task is to find the length of the smallest sub-array which has sequence {0, 1, 2, 3,… Read More »

Given an array of strings arr[], the task is to find the largest string in the array which is made up of the other strings… Read More »

Given an array of alphanumeric characters. The task is to find the longest contiguous sub-array which has equal numbers of letters (alphabets) and numbers (numeric… Read More »

Given an array of pairs of numbers of size N. In every pair, the first number is always smaller than the second number. A pair… Read More »

Given a binary array arr[] of 1’s and 0’s of length N. The task is to find the number of elements which are different with… Read More »

Given a matrix mat[][] of size m * n which is sorted in row-wise fashion and an array row[], the task is to check if… Read More »