## Minimize the absolute difference of sum of two subsets

Given a number n, divide first n natural numbers (1, 2, …n) into two subsets such that difference between sums of two subsets is minimum.… Read More »

Given a number n, divide first n natural numbers (1, 2, …n) into two subsets such that difference between sums of two subsets is minimum.… Read More »

You are given an array of n-element. You have to make subsets from the array such that no subset contain duplicate elements. Find out minimum… Read More »

Given a floating point number, check whether it is even or odd. We can check whether a integer is even or odd by dividing its… Read More »

Given the dimensions of cylindrical water tank, spherical solid balls and the amount of water present in the tank check if water tank will overflow… Read More »

Given a differential equation dy/dx = f(x,y) with initial condition y(x0) = y0. Find its approximate solution using Euler method. Euler Method : In mathematics… Read More »

Calculate volume and surface area of a hemisphere. Hemisphere : In geometry, it is an exact half of a sphere. We can find many of… Read More »

Given length of sides of equilateral triangle (s), and velocities(v) of each animal tagged on the vertices of triangle, find out the time after which… Read More »

Given an array of numbers, find the maximum product formed by multiplying numbers of an increasing subsequence of that array. Note: A single number is… Read More »

The Leibniz harmonic triangle is a triangular arrangement of unit fractions in which the outermost diagonals consist of the reciprocals of the row numbers and… Read More »

A triangular number or triangle number counts objects arranged in an equilateral triangle, as in the diagram on the right. The n-th triangular number is… Read More »

Given n, how many distinct Max Heap can be made from n distinct integers? Examples: Input : n = 3 Output : Assume the integers… Read More »

We are given a sequence of numbers from 1 to n. Each permutation in the sequence that we need to generate should differ from the… Read More »

Given a set of positive integers, find all its subsets. Examples: Input : 1 2 3 Output : // this space denotes null element. 1… Read More »

Given an array of strings, print them in alphabetical (dictionary) order. If there are duplicates in input array, we need to print all the occurrences.… Read More »

Given a tuple, sort the list of tuples in increasing order by any key in tuple. Examples: Input : tuple = [(2, 5), (1, 2),… Read More »