RosettaCodeData/Task/Fibonacci-sequence/Plain-English/fibonacci-sequence.plain

9 lines
259 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
To find a fibonacci number given a count:
Put 0 into a number.
Put 1 into another number.
Loop.
If a counter is past the count, put the number into the fibonacci number; exit.
Add the number to the other number.
Swap the number with the other number.
Repeat.