|
|
|
|
|
by masklinn
1213 days ago
|
|
> It seems obvious in hindsight It's not, because most languages don't have an `else` clause in their for loop (and in my experience with Python that clause is quite confusing so its use is not common). And a for loop can be executed 0 times, so without a mechanism for a fallback it might not have a value to yield. |
|
Say like the for loops in racket, or my own loops for guile scheme: https://git.sr.ht/%7Ebjoli/goof-loop