## Print combinations of distinct numbers which add up to give sum N

Given a positive integer N, the task is to find out all the combinations of positive integers that add upto the given integer N. The… Read More »

- Maximum of all Subarrays of size k using set in C++ STL
- Find Maximum and Minimum element in a Set in C++ STL
- Count triplet pairs (A, B, C) of points in 2-D space that satisfy the given condition
- Print all integers that are sum of powers of two given numbers
- Find the lexicographically smallest sequence which can be formed by re-arranging elements of second array
- Minimum Numbers of cells that are connected with the smallest path between 3 given cells
- How to delete an element from the Set by passing its value in C++
- Print combinations of distinct numbers which add up to give sum N
- Greatest number less than equal to B that can be formed from the digits of A
- Total distinct pairs from two arrays such that second number can be obtained by inverting bits of first
- Distinct pairs from given arrays (a[i], b[j]) such that (a[i] + b[j]) is a Fibonacci number
- Distinct state codes that appear in a string as contiguous sub-strings
- How to delete a range of values from the Set using Iterator
- Find the Jaccard Index and Jaccard Distance between the two given sets

Given a positive integer N, the task is to find out all the combinations of positive integers that add upto the given integer N. The… Read More »

Given two sets of integers s1 and s2, the task is to find the Jaccard Index and the Jaccard Distance between the two sets. Examples:… Read More »

Given two arrays A and B of N integers. Reorder the elements of B in itself in such a way that the sequence formed by… Read More »

Given two arrays a[] and b[], the task is to count the pairs (a[i], b[j]) such that (a[i] + b[j]) is a Fibonacci number.Note that… Read More »

Given two arrays arr1[] and arr2[], the task is to take an element from first array (say a) and one element from second array (say… 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 two integers A and B, the task is to find the greatest number ≤ B that can be formed using all the digits of… Read More »

Given N points in 2 dimensional space. The task is to count the number of triplets pairs (A, B, C) such that point B is… Read More »

Given an array of size N and an integer K, the task is to find the maximum for each and every contiguous sub-array of size… Read More »

Given three non-negative integers x, y and bound, the task is to print all the powerful integer ≤ bound in sorted order. A powerful integer… Read More »

Given a Set, the task is to find the maximum and minimum element of this set in C++ STL. Examples: Input: set={1, 6, 15, 10,… Read More »

Given a Set, the task is to remove the last element from this Set in C++. Examples: Input: set = [10 20 30 70 80… Read More »

Given a Set, the task is to delete a range of values from this Set using Iterator. Example: Input: set = [10 20 30 40… Read More »

Given coordinates of 3 cells (X1, Y1), (X2, Y2) and (X3, Y3) of a matrix. The task is to find the minimum path which connects… Read More »

Given a string S of length N consisting of lowercase English letters and an integer K. Find the lexicographically smallest string T of length K,… Read More »