Re: Iterable Flattener with Depth.

2007-11-02 Thread Ian Clark
thebjorn wrote: On Nov 2, 6:32 am, praddy [EMAIL PROTECTED] wrote: On Nov 1, 5:03 pm, [EMAIL PROTECTED] wrote: Pradeep Jindal: Any comments? Something with similar functionality (plus another 20 utility functions/classes or so) has probably to go into the std lib... :-) Bye, bearophile

Re: Iterable Flattener with Depth.

2007-11-02 Thread thebjorn
On Nov 2, 6:32 am, praddy [EMAIL PROTECTED] wrote: On Nov 1, 5:03 pm, [EMAIL PROTECTED] wrote: Pradeep Jindal: Any comments? Something with similar functionality (plus another 20 utility functions/classes or so) has probably to go into the std lib... :-) Bye, bearophile Same

Re: Iterable Flattener with Depth.

2007-11-02 Thread Pradeep Jindal
On Friday 02 Nov 2007 10:43:45 pm Ian Clark wrote: thebjorn wrote: On Nov 2, 6:32 am, praddy [EMAIL PROTECTED] wrote: On Nov 1, 5:03 pm, [EMAIL PROTECTED] wrote: Pradeep Jindal: Any comments? Something with similar functionality (plus another 20 utility functions/classes or so) has

Iterable Flattener with Depth.

2007-11-01 Thread Pradeep Jindal
Hi, 5 minute solution to one of my requirements. I wanted to flatten iterables upto a specific depth. To be true, didn't search for it on the internet prior to writing this one. def flatten_iter(my_iter, depth=None): my_iter can be a iterable except string containing nested

Re: Iterable Flattener with Depth.

2007-11-01 Thread bearophileHUGS
Pradeep Jindal: Any comments? Something with similar functionality (plus another 20 utility functions/classes or so) has probably to go into the std lib... :-) Bye, bearophile -- http://mail.python.org/mailman/listinfo/python-list

Re: Iterable Flattener with Depth.

2007-11-01 Thread praddy
On Nov 1, 5:03 pm, [EMAIL PROTECTED] wrote: Pradeep Jindal: Any comments? Something with similar functionality (plus another 20 utility functions/classes or so) has probably to go into the std lib... :-) Bye, bearophile Same Here! - Pradeep --