On Sun, 14 Apr 2013 22:35:42 -0400, Roy Smith wrote: > In article <[email protected]>, > Walter Hurry <[email protected]> wrote: > >> On Mon, 15 Apr 2013 11:29:17 +1000, Chris Angelico wrote: >> >> > There are actually a lot of optimizations done, so it might turn out >> > to be O(n) in practice. But strictly in the Python code, yes, this is >> > definitely O(n*n). >> >> In any event, Janssen should cease and desist offering advice here if >> he can't do better than that. > > That's a little harsh. Sure, it was a "sub-optimal" way to write the > code (for all the reasons people mentioned), but it engendered a good > discussion.
Agreed. I'd rather people come out with poor code, and LEARN from the answers, than feel that they dare not reply until they're an expert. -- Steven -- http://mail.python.org/mailman/listinfo/python-list
