PL/SQL Program for Fibonacci Series

Here you will get pl/sql program for fibonacci series.

It is a series in which next number is the sum of previous two numbers.

 

PL/SQL Program for Fibonacci Series

 

Output

Enter value for n: 6
old 5: n number:=&n;
new 5: n number:=6;
Fibonacci series is:
0
1
1
2
3
5
8

3 thoughts on “PL/SQL Program for Fibonacci Series

    1. Jayanth R S

      as we have already printed first and second number, we should use (3..n) to generate 5 terms(0 1 2 3 5).

      Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

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