Create a Python script that will display the next 5 numbers in the sequence where each number is the sum of the previous two.
This is my text file:
8 3
4 5
6 2
The sample output should be like this when I run the code:
8 3 11 14 25 39 64
4 5 9 14 23 37 50
6 2 8 10 18 28 46
I need the code to have the python script that will display the next 5 numbers from my text file stated above.
Comments