pythonbeginner

Fibonacci Yield Generator

Memory-efficient Python generator yielding Fibonacci numbers

By ApeType Staff·7 lines·135 characters·1,420 total attempts
SOURCE CODE·python
def fibonacci_stream(limit: int): a, b = 0, 1 count = 0 while count < limit: yield a a, b = b, a + b count += 1
UTF-8 · Tab indentationStandard Strict Parsing
TRANSCRIBE

Ready when you are.

Test your muscle memory and transcription speed against this exact snippet.

Start Typing
Tip: Press Esc anytime to restart

Best runs on this snippet

#TypistAccWPM
1nypava100%104
2nypava100%104
3nypava100%104
4Abel Gideon100%98
5Abel Gideon100%98