## Sum of products of all possible K size subsets of the given array

Given an array arr[] of N non-negative integers and an integer 1 ≤ K ≤ N. The task is to find the sum of the… Read More »

## Number of subsets with sum divisible by M | Set 2

Given an array arr[] of N integers and an integer M, the task is to find the number of non-empty subsequences such that the sum… Read More »

## Sum of subsets of all the subsets of an array | O(2^N)

Given an array arr[] of length N, the task is to find the overall sum of subsets of all the subsets of the array. Examples:… Read More »

## Count of subsets with sum equal to X

Given an array arr[] of length N and an integer X, the task is to find the number of subsets with sum equal to X.… Read More »

## Sum of subsets of all the subsets of an array | O(N)

Given an array arr[] of length N, the task is to find the overall sum of subsets of all the subsets of the array. Examples:… Read More »

## Number of subsets with a given OR value

Given an array arr[] of length N, the task is to find the number of subsets with a given OR value M. Examples: Input: arr[]… Read More »

## Number of subsets with a given AND value

Given an array arr of length N and an integer X, the task is to find the number of subsets whose AND value is X.… Read More »

## Sum of subsets of all the subsets of an array | O(3^N)

Given an array arr[] of length N, the task is to find the overall sum of subsets of all the subsets of the array. Examples:… Read More »

## Count non-adjacent subsets from numbers arranged in Circular fashion

Given that N people are sitting in a circular queue numbered from 1 to N, the task is to count the number of ways to… Read More »

## Number of subsets whose mean is maximum

Given an array arr[] of size N, the task is to count the number of subsets of arr[] whose mean is maximum. Examples: Input: arr[]… Read More »

## Product of values of all possible non-empty subsets of given Array

Given an array of size N. The task is to find the product of values of all possible non-empty subsets of the given array. Examples:… Read More »

## Sum of values of all possible non-empty subsets of the given array

Given an array arr[] of N integers, the task is to find the sum of values of all possible non-empty subsets of array the given… Read More »

## Prime Subset Product Problem

Given an array arr[] of N integers. Value of a subset of array A is defined as the product of all prime numbers in that… Read More »

## Sum of squares of all Subsets of given Array

Given an array arr[]. The value of a subset of array A is defined as the sum of squares of all the numbers in that… Read More »

## Count of subsets not containing adjacent elements

Given an array arr[] of N integers, the task is to find the count of all the subsets which do not contain adjacent elements from… Read More »