18 using a list of list in a fucntion


#1

stuck of combining the 2 list in a fucntion


#2

Can you include your code and which part you don't understand?


#3

I'm also stuck a little. My code look slike this now.

n = [[1, 2, 3], [4, 5, 6, 7, 8, 9]]
def flatten(lists):
results=[]
for numbers in lists:
for item in numbers:
results+= numbers.append(item)
return results

print flatten(n)


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.