Question
C++ programming The Fibonacci series is a sequence of integers starting with 0and 1. All subsequent values in the sequence are the sum of the 2previous values. 0,1,1,2,3,5,8,13,21... I need help creating a formula that will return a bool typevalue indicating wether a given number is part of the Fibonaccisequence (true) or not (false). C++ programming The Fibonacci series is a sequence of integers starting with 0and 1. All subsequent values in the sequence are the sum of the 2previous values. 0,1,1,2,3,5,8,13,21... I need help creating a formula that will return a bool typevalue indicating wether a given number is part of the Fibonaccisequence (true) or not (false).
Explanation / Answer
please rate - thanks #include bool isfib(int); int main() { int first,second,next,i; int n; coutn; if(isfib(n)) cout