# Category Archives: Mathematical (adsbygoogle = window.adsbygoogle || []).push({});

## Count of integers of the form (2^x * 3^y) in the range [L, R]

Given a range [L, R] where 0 ≤ L ≤ R ≤ 108. The task is to find the count of integers from the given… Read More »

## Program to find the rate percentage from compound interest of consecutive years

Given two integers N1 and N2 which is the Compound Interest of two consecutive years. The task is to calculate the rate percentage. Examples: Input:… Read More »

## Ratio of the distance between the centers of the circles and the point of intersection of two transverse common tangents to the circles

Given two circles, of given radii, such that the circles don’t touch each other. The task is to find the ratio of the distance between… Read More »

## Rearrange the array to maximize the number of primes in prefix sum of the array

Given an array arr[] of 1’s and 2’s, the task is to re-arrange the array in such a way that the prefix sum of the… Read More »

## Count Pairs from two arrays with even sum

Given two arrays A[] and B[] of N and M integers respectively. The task is to count the number of unordered pairs formed by choosing… Read More »

## Count the number of primes in the prefix sum array of the given array

Given an array arr[] of N integers, the task is to count the number of primes in the prefix sum array of the given array.… Read More »

## Maximum number that can be display on Seven Segment Display using N segments

Given a positive integer N. The task is to find the maximum number that can be displayed on seven segment display using N segments. Seven… Read More »

## Generate an array of size K which satisfies the given conditions

Given two integers N and K, the task is to generate an array arr[] of length K such that: arr + arr + … +… Read More »

## Find prime number K in an array such that (A[i] % K) is maximum

Given an array arr[] of n integers. The task is to find an element from the array K such that K is prime. And, arr[i]… Read More »

## Minimum number of given operations required to reduce the array to 0 element

Given an array arr[] of N integers. The task is to find the minimum number of given operations required to reduce the array to 0… Read More »

## Generate an Array in which count of even and odd sum sub-arrays are E and O respectively

Given three integers N, E and O. The task is to find an array of size N such that the number of sub-arrays of sum… Read More »

## Minimum operations required to change the array such that |arr[i] – M| <= 1

Given an array[] of integers, the task is find the minimum number of operations required to change the array elements such that for any positive… Read More »

## Minimum integer such that it leaves a remainder 1 on dividing with any element from the range [2, N]

Given an integer N, the task is to find the minimum possible integer X such that X % M = 1 for all M from… Read More »

## Maximum number of edges in Bipartite graph

Given an integer N which represents the number of Vertices. The Task is to find the maximum number of edges possible in a Bipartite graph… Read More »

## Program to find the number of region in Planar Graph

Given two integers V and E which represent the number of Vertices and Edges of a Planar Graph. The Task is to find the number… Read More »