Two Strings are anagrams of each other if both Strings must contain same characters and same number of frequency. Example : Input : a="abcd" b="bcdf" now to make both strings to anagrams Read more →
Latest tutorials
505 postsGiven an array arr of positive numbers of size N. Our task is to print all the monk numbers in the array. An element is monk number if it has occurred only Read more →
Given an integer n we have to calculate the no of times the bits flips in binary representation form 0 to n. Examples : Input : n = 5 Output : 8 Read more →
Given an integer N, denoting strings of even length and an integer M, denoting strings of odd length. The task is to count total strings whose length is even after concatenation of Read more →
Given 3 integers N, P and X, you have to determine if a sequence [S1, S2, …., SN] can be constructed such that any pair of the sequence satisfying the constraint Si Read more →
Given an array w of size n, consisting of non-negative integers, the task is to find the maximum number of pairs that can be formed, such that the sum of each of Read more →
Given a starting position as 0 and three integers X, Y, and K, the task is to find the position after K jumps, the condition for the jumps are as follows: if Read more →
Given a number N, the task is to find the sum of the first N Centered nonadecagonal numbers. The first few Centered nonadecagonal number are 1, 20, 58, 115, 191, 286 … Read more →
Given an array arr[] containing positive integer elements, and a positive integer K. The problem is to find the length of longest subarray, whose sum is not divisible by K Examples : Read more →
Given first two digits d1 and d2 and a relation to find the other digits till dk. Find if the number formed is divisible by 3. digit di is the sum of Read more →