>
> For simple inputs, the two approaches have similar performance.  On
> complex inputs, my tests show the iterative version tends to run about
> twice as fast.
>
> Try running on an extreme input like:
> ["ACDFG" "A" "B" "C" "D" "E" "F" "ABCD" "G" "H" "I" "ABEG" "J" "K"
> "BCDE" "L" "ABCDG" "M" "EF" "NABC" "ABCDFG" "ABDEFG" "DGHI" "ABCDEFG"]
>
> and let me know if you also see the 2x performance difference.

Yes, yours runs more than 2x faster on this input.  On the other hand,  
mine runs almost 2x faster on
(range 3000) (range 3000) ... As far as I can tell, yours is faster  
when there are a large number of input seqs, especially if any of them  
have 0 or 1 elements.  Anyway, I'm happy with either implementation,  
although probably they should take multiple seq arguments rather than  
a seq of seqs?

-Jason

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to clojure@googlegroups.com
To unsubscribe from this group, send email to 
clojure+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to