Move some recursion issues to the recursion module.

This commit is contained in:
Dave Halter
2016-07-27 22:23:30 +02:00
parent 4c6669e081
commit 01e577be8b
3 changed files with 39 additions and 42 deletions

View File

@@ -379,20 +379,6 @@ for i in set(a for a in [1]):
i
# -----------------
# Recursions
# -----------------
def to_list(iterable):
return list(set(iterable))
def recursion1(foo):
return to_list(to_list(foo)) + recursion1(foo)
#? int()
recursion1([1,2])[0]
# -----------------
# Merged Arrays
# -----------------