## Minimum increments to convert to an array of consecutive integers

Given an array arr[] with N elements, the task is to find the minimum number of operations required so that an Arithmetic Progression with the… Read More »

## Change one element in the given array to make it an Arithmetic Progression

Given an array which is an original arithmetic progression with one element changed. The task is to make it an arithmetic progression again. If there… Read More »

## Sum of i * countDigits(i)^2 for all i in range [L, R]

Given a range [L, R], the task is to find the sum i * countDigits(i)2 for all i ∈ [L, R] where countDigits(i) is the… Read More »

## Series summation if T(n) is given and n is very large

Given a sequence whose nth term is T(n) = n2 – (n – 1)2 The task is to evaluate the sum of first n terms… Read More »

## Convert given array to Arithmetic Progression by adding an element

Given an array arr[], the task is to find an element that can be added to the array in order to convert it to Arithmetic… Read More »

## Print first N terms of series (0.25, 0.5, 0.75, …) in fraction representation

Given an integer N, the task is to print the first N terms of the series in their fraction form i.e. 1/4, 1/2, 3/4, 1,… Read More »

## Find the nth term of the series 0, 8, 64, 216, 512, . . .

Given an integer N, the task is to find the Nth term of the following series: 0, 8, 64, 216, 512, 1000, 1728, . .… Read More »

## Arithmetic Mean

Arithmetic mean, also called the average or average value, is the quantity obtained by summing two or more numbers or variables and then dividing by… Read More »

## Arithmetic Progression

A sequence of numbers is called an Arithmetic progression if the difference between any two consecutive terms is always the same. In simple terms, it… Read More »

## Sum of first N natural numbers which are divisible by X or Y

Given a number N. Given two numbers X and Y, the task is to find the sum of all those numbers from 1 to N… 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 the sum of all multiples of 2 and 5 below N

Given a number N. The task is to find the sum of all multiples of 2 and 5 below N ( N may be up… Read More »

## Find the Nth term of the series 1 + 2 + 6 + 15 + 31 + 56 + …

Given an integer . The task is to write a program to find the N-th term of the given series: 1 + 2 + 6… Read More »

## Program to find the angles of a quadrilateral

Given that all the angles of a quadrilateral are in AP having common difference ‘d’, the task is to find all the angles. Examples: Input:… Read More »

## Sum of the numbers upto N that are divisible by 2 or 5

Given a number n. The task is to find the sum of numbers up to n, that are divisible 2 or 5. Examples: Input: n… Read More »