Python Program for Fibonacci Series

Python Program for Fibonacci Series

Here you will get the program code of Python program for Fibonacci Series. Here we are taking the n value from the user, calculating the Fibonacci series using for loop and if-else, and printing the result.

 

Fibonacci series is the sequence of the addition of last two preceding numbers.

for example:

The first 10 number’s Fibonacci series are 0, 1, 1, 2, 3, 5, 8, 13, 21, 34.

 

Example Code of Python Program for Fibonacci Series

Output

Input the value of ‘n’: 15
Fibonacci series:
0 1 1 2 3 5 8 13 21 34 55 89 144 233 377

 

 

Check out our other Python Programming Examples

 

 

 

 

Leave a Comment

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

Scroll to Top