## Number of array elements derivable from D after performing certain operations

Given an array of N integers and 3 integers D, A and B. The task is to find the number of array elements that we… Read More »

## Find an integer X which is divisor of all except exactly one element in an array

Given an array of integers. Find an integer X which is the divisor of all except for exactly one element in the given array. Note:… Read More »

## Maximum GCD of N integers with given product

Given N integers with unknown values (ai > 0) having product P. The task is to find the maximum possible greatest common divisor of these… Read More »

## Minimum value that divides one number and divisible by other

Given two integer p and q, the task is to find the minimum possible number x such that q % x = 0 and x… Read More »

## LCM of N numbers modulo M

Given an array arr[] of integers, the task is to find the LCM of all the elements of the array modulo M where M =… Read More »

## Count numbers in a range having GCD of powers of prime factors equal to 1

Given a range represented by two positive integers L and R. The task is to count the numbers from the range having GCD of powers… Read More »

## Time taken by two persons to meet on a circular track

Given integers L, S1 and S2 where L is the length of a circular track in meters, S1 and S2 are the speeds of two… Read More »

## Minimum sum of the elements of an array after subtracting smaller elements from larger

Given an array arr, the task is to find the minimum sum of the elements of the array after applying the following operation: For any… Read More »

## Find three integers less than or equal to N such that their LCM is maximum

Given a number N(>=3). The task is to find the three integers (<=N) such that LCM of these three integers is maximum. Examples: Input: N… Read More »

## LCM and HCF of fractions

Given n fractions as two arrays Num and Den. The task is to find out the L.C.M of the fractions. Examples: Input: num[] = {1,… Read More »

## Find the other number when LCM and HCF given

Given a number A and L.C.M and H.C.F. The task is to determine the other number B. Examples: Input: A = 10, Lcm = 10,… Read More »

## Sum of common divisors of two numbers A and B

Given two number A and B, the task is to find the sum of common factors of two numbers A and B. The numbers A… Read More »

## Sum of multiples of A and B less than N

Given a number N, the task is to find the sum of all the multiples of A and B below N. Examples: Input:N = 11,… Read More »

## Find two numbers whose sum and GCD are given

Given sum and gcd of two numbers and . The task is to find both the numbers a and b. If the numbers do not… Read More »

## Minimum number of cuts required to make circle segments equal sized

Given an array of elements where each element in the array represents the degree ( 0 <= a[i] <= 359 ) at which there is… Read More »