Skip to content
Home » C Programs » Fibonacci Series Program in C Using Array

Fibonacci Series Program in C Using Array

Simple fibonacci series in c using array. In this program, we can execute and find the Fibonacci series program using an array for beginners to understand the implementation of the Fibonacci series in an array.  

Fibonacci Series in C

The Fibonacci sequence is a collection of numbers that starts with one or zero and ends with one, with each number (called a Fibonacci number) equal to the sum of the two numbers before it. 

The golden ratio is roughly 1.618, which is represented by the Greek letter phi. The golden ratio is best approximated by the renowned “Fibonacci numbers.” 

Fibonacci numbers are an infinite series that starts with 0 and 1 and continues by adding the two numbers before it. 

Array Definition in C

An array is a collection of data elements of the same type stored in contiguous memory regions. 

Arrays are a derived data type in the C programming language that may hold primitive data types like int, char, double, float, and so on. 

An array is a collection of elements of the same kind that are stored in contiguous memory locations and may be accessed separately using a unique identifier’s index. By using this method we have executed the fibonacci series program in c using array

fibonacci series in c using array

//fibonacci series in c using array
#include<stdio.h> 
int main()
{
int fib[24];
int i;
fib[0] = 0;
fib[1] = 1;
for(i = 2; i <24; i++)
fib[i] = fib[i-1] + fib[i-2];
for (i = 0; i < 24; i++)
printf(" %6dn",fib[i]);
}

Output: 







Reverse a Number in C Using For Loop 

Reverse a Number in C Using Function 

C Program to Reverse a Number Using Recursion 

Armstrong Number in C Using Function 

Fibonacci Series Program in C Using Array 

Fibonacci Series Program in C Using Function 

Palindrome Program in C Using String Functions 

Palindrome Program in C Using Recursion 

Prime or Not in C Using Function 

LCM of Two Numbers in C Using For Loop 

Binary releases – Code::Blocks

GDB online Debugger | Compiler – Code, Compile, Run, Debug online C, C++

Online Compiler and Editor/IDE for Java, C/C++, PHP, Python, Perl, etc

C (programming language)

Applications of C Programming That Will Make You Fall In Love With C