Summation of floor of harmonic progression

Given an integer N, the task is to find the summation of the harmonic series . Examples: Input: N = 5 Output: 10 floor(3/1) +… Read More »

Program to find sum of harmonic series

Harmonic series is inverse of a arithmetic progression. In general, the terms in a harmonic progression can be denoted as 1/a, 1/(a + d), 1/(a… Read More »

Harmonic Progression

A sequence of numbers is called a Harmonic progression if the reciprocal of the terms are in AP. In simple terms, a, b, c, d,… Read More »

Check if the given number is Ore number or not

Given a positive integer n, check if it is an Ore number or not. Print ‘YES’ if n is an ore number otherwise print ‘NO’.… Read More »

Program to find the Nth Harmonic Number

Given a number N. The task is to find the Nth Harmonic Number. Let the nth harmonic number be Hn. The harmonic series is as… Read More »

Harmonic progression Sum

Given the first element of the progression ‘a’, common difference between the element ‘d’ and number of terms in the progression ‘n’, where . The… Read More »

Sum of series (n/1) + (n/2) + (n/3) + (n/4) +…….+ (n/n)

Given a value n, find the sum of series, (n/1) + (n/2) + (n/3) + (n/4) +…….+(n/n) where the value of n can be up… Read More »

Progressions (AP, GP, HP)

Progressions (or Sequences and Series) are numbers arranged in a particular order such that they form a predictable order. By predictable order, we mean that… Read More »

Expected Number of Trials until Success

Consider the following famous puzzle. In a country, all families want a boy. They keep having babies till a boy is born. What is the… Read More »

Program to find sum of series 1 + 1/2 + 1/3 + 1/4 + .. + 1/n

If inverse of a sequence follows rule of an A.P i.e, Arithmetic progression, then it is said to be in Harmonic Progression.In general, the terms… Read More »