Fibonacci Sequence For Loop
24 ビュー (過去 30 日間)
Write a script which calculates F(20). Using a for loop. At any given time you need only store the three active members of the sequence say F_Curr, F_Old, F_Older, which you will 'shuffle' appropiately. Refer to your current count as 'F_curr'
回答 (1 件)
Jemima Pulipati 2021 年 2 月 18 日
From my understanding, you want to generate Fibonacci series using three variables inside a for loop.
The following answers from the community might be of relevance to you.