Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- static int FibonacciIteraviteOneLoop(int num)
- {
- System.Numerics.BigInteger current = 1;
- System.Numerics.BigInteger previous = 0;
- int i = 1;
- while ((current + previous) % num != 0)
- {
- System.Numerics.BigInteger temp = current + previous;
- previous = current;
- current = temp;
- i++;
- }
- return i + 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement