Update snippet titles

This commit is contained in:
Isabelle Viktoria Maciohsek
2022-02-13 14:41:40 +02:00
parent b3b60cd838
commit 0f3e0f9ed0
48 changed files with 52 additions and 52 deletions

View File

@ -1,5 +1,5 @@
---
title: unfold
title: Unfold list
tags: function,list,advanced
firstSeen: 2020-01-02T20:17:51+02:00
lastUpdated: 2020-11-02T19:28:35+02:00
@ -14,7 +14,7 @@ Builds a list, using an iterator function and an initial seed value.
```py
def unfold(fn, seed):
def fn_generator(val):
while True:
while True:
val = fn(val[1])
if val == False: break
yield val[0]