Given a number N check if it part of Fibonacci series or not?
Flow chart assignment
Hello @r_apaar
a number N is prime number , if it is divisible by only 2 numbers i.e 1 and itself .
so iterate from 1 to N and count number of divisor.
if count ==2 then it is prime
otherwise not
refer this->
QUESTIONS i am having problem are as follows:-
-
Given a number N check if it part of fibonacci or not? (Flowchart assignment)
-
Write a program to swap two numbers without using third variable.
the idea is to keep generating fibonnaci number till the generated fibonacci number is < given number.
once this condition get false . check if that fibonnaci number is equal to given no or not.
if it is then print yes otherwise no.
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.