INTRODUCING 5 - days-a-week problem solving session for Math Olympiad and ISI Entrance. Learn More 

October 19, 2019

What is the 30th term in the Fibonacci series?

We all know about the famous Fibonacci (was the name given to Leonardo Pisano) Series . In this series each number is the sum of the two preceding ones, starting from 0 and 1. That is \(F_0\)=0 and \(F_1\)=1


\(F_n\)=\(F_{n−1}\)+\(F_{n−2}\) for n>1

In some old books \(F_0\) is omitted and the the entire things starts with \(F_1\)and \(F_2\)that is \(F_1\)=\(F_2\)=1

so it starts like this 0,1,1,2,3,5,8,13,……..

Now in order to find the 30th term of the above mentioned series we write a program in C and that is

  1. #include <stdio.h>
  2. Void main ()
  3. {
  4. long int i, n, t1 = 0, t2 = 1, nextTerm;
  5. printf("Enter the number of terms: ");
  6. scanf("%li", &n);
  7. printf("Fibonacci Series: ");
  8. for (i = 1; i <= n; ++i)
  9. {
  10. printf("%d, ", t1);
  11. nextTerm = t1 + t2;
  12. t1 = t2;
  13. t2 = nextTerm;
  14. }
  15. }

After compiling the above program in C , we enter the value of ?n as 30 and the output is


Here 514229 is the 30th term of the Fibonacci Series

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Cheenta. Passion for Mathematics

Advanced Mathematical Science. Taught by olympians, researchers and true masters of the subject.