Skip to content

Commit 46ecf2b

Browse files
author
Jake Simones
committed
Fix typos in examples
1 parent 753331a commit 46ecf2b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

toolz/functoolz.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -839,7 +839,7 @@ def unfold(func, x):
839839
... return (x * 2, x + 1)
840840
...
841841
>>> list(unfold(doubles, 1))
842-
[2, 4, 6, 9, 10, 12, 14, 16, 18, 20]
842+
[2, 4, 6, 8, 10, 12, 14, 16, 18, 20]
843843
844844
If ``x`` has type ``A`` and the generator yields values of type ``B``,
845845
then ``func`` has type ``Callable[[A], Optional[Tuple[B, A]]]``.
@@ -865,7 +865,7 @@ def unfold_(predicate, func, succ, x):
865865
>>> double = lambda x: x * 2
866866
>>> inc = lambda x: x + 1
867867
>>> list(unfold(lte10, double, inc, 1))
868-
[2, 4, 6, 9, 10, 12, 14, 16, 18, 20]
868+
[2, 4, 6, 8, 10, 12, 14, 16, 18, 20]
869869
870870
If ``x`` has type ``A`` and the generator yields values of type ``B``,
871871
then ``predicate`` has type ``Callable[[A], bool]``, ``func`` has type

0 commit comments

Comments
 (0)