Tutorialspoint.dev
Welcome To Tutorialspoint.dev
Officially launched 18th May 2019
Mathematical Fibonacci Mathematical

An efficient way to check whether n-th Fibonacci number is multiple of 10

We are given a variable n, we need to find whether Fibonacci number will be multiple of 10 or not. Examples: Input : 15 Output : Yes Input : 17 Output : No Reco...
Mathematical Technical Scripter Fibonacci

Finding number of digits in n’th Fibonacci number

Given a number n, find number of digits in n’th Fibonacci Numbers. First few Fibinacci numbers are 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, …. Exa...
Mathematical Fibonacci Mathematical

Even Fibonacci Numbers Sum

Given a limit, find the sum of all the even-valued terms in the Fibonacci sequence below given limit. The first few terms of Fibonacci Numbers are, 1, 1, 2, 3, 5, 8,...
Mathematical Fibonacci Mathematical

Find Index of given fibonacci number in constant time

We are given a Fibonacci number. First few Fibonacci numbers are 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, ….. We have to find index of given Fibonacci num...
Mathematical Fibonacci tail-recursion

Tail Recursion for Fibonacci

Write a tail recursive function for calculating the n-th Fibonacci number. Examples : Input : n = 4 Output : fib(4) = 3 Input : n = 9 Output : fib(9) = 34 Prerequi...
Mathematical Fibonacci Mathematical

Non Fibonacci Numbers

Given a positive integer n, the task is to print the n’th non Fibonacci number. The Fibonacci numbers are defined as: Fib(0) = 0 Fib(1) = 1 for n >1, Fib(n)...
Mathematical Fibonacci Mathematical

Sum of Fibonacci Numbers

Given a number positive number n, find value of f0 + f1 + f2 + …. + fn where fi indicates i’th Fibonacci number. Remember that f0 = 0, f1 = 1, f2 = 1, f...
Mathematical School Programming Fibonacci

Program to print first n Fibonacci Numbers Set 1

Following is simple program to print first n Fibonacci numbers. Examples : Input : n = 3 Output : 1 1 2 Input : n = 7 Output : 1 1 2 3 5 8 13 ...
Mathematical Fibonacci Modular Arithmetic

Fibonacci modulo p

The Fibonacci sequence is defined as = + where = 1 and = 1 are the seeds. For a given prime number p, consider a new sequence which is (Fibonacci sequence) mod...
Mathematical Fibonacci number-theory

Prime numbers and Fibonacci

Given a number, find the numbers (smaller than or equal to n) which are both Fibonacci and prime. Examples: Input : n = 40 Output: 2 3 5 13 Explanation : Here, range(...

Subscribe to Our Newsletter