Not able to make flowchart

  1. flowchart of
    given a number N check if it is a part of fibonacci series or not???

Hey @tanvi2002
First few Fibonacci numbers are 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 141, …
You know that in fibonacci series…0th index number is 0 and 1st index number is 1.
After that, you can get the value at 2nd index as: value at 0th index+ value at 1st index
Similary value at 3rd index is: value at 1st index+ value at second index.

So we can conclude with a formula:

Value at ith index= value at (i-1)th index + value at (i-2)th index. (where i>=2)
So to check if the given number is in the fibonacci series or not run this iteration till condition:
while(value at ith index <= given number )
So if this series ends with the given number, you can say that the number belongs to fibonacci series.
Else you can say that it in not in the fibonacci series.

Replace empty box by this :
If Y==Num return true
Else return false

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.