Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
fibonacci
#include<stdio.h> int main() { int n; int first = 0; int second = 1; int next; int x; scanf("%d",&n); printf("terms of Fibonacci series are : %d\n",n); for ( x = 0 ; x < n ; x++) { if ( x <= 1 ) next = x; else { next = first + second; first = second; second = next; } printf("%d\n",next); } return 0; }
run
|
edit
|
history
|
help
0
Building squares using smallest amount of matches
150114_ArrayOrdenado
square pyramid
Hello
stack
Matrix rotation 90-degree
menu
bitwise operations
co_4
B_141202_CTYPE