News for hackers. Stuff that matters.
Re:Why it’s hard for programmers to write a program to flatt... by contravariant on Friday February 24, 2017 @12:46PM (#13725811)
It should work in python 3.3+, provided you make a method isIterable to detect whether something is an iterator or not. For lower versions of python you can't use the phrase 'yield from', so you need to iterate over flatten(y) manually and yield each element.

There are no comments on this comment yet.