Skip to main content

Timeline for Generating 3 combinations in Python

Current License: CC BY-SA 3.0

11 events
when toggle format what by license comment
Nov 9, 2015 at 4:35 vote accept CodeYogi
Oct 13, 2015 at 12:11 comment added Peilonrayz @CodeYogi If you use the Python version of combinations, then you can see that, your function is faster. For me yours was more than 10 times faster...
Oct 13, 2015 at 10:08 comment added CodeYogi I never wanted to emphasize on it. My bad if that point got highlighted. I wanted if I can improve performance any further.
Oct 13, 2015 at 9:50 comment added rahmu @CodeYogi reinventing is great for understanding, but when you said you're slow compared to the std lib, you're comparing apples to oranges. The standard library is full of optimizations.
Oct 13, 2015 at 9:37 comment added outoftime @CodeYogi 090 elements: 6.353836 26.277946 is best proof of my words. But it is only for cpython not pypy.
Oct 13, 2015 at 9:36 comment added outoftime I'd like to join discussion with title "std:: or not std::" but we are talking about python, not c++.
Oct 13, 2015 at 9:32 comment added CodeYogi In fact these approach are quite useful when your coding environment doesn't allow external libraries or your use case is quite restricted.
Oct 13, 2015 at 9:31 comment added CodeYogi @JaDogg, reinventing and understanding is quite different things I think. In that manner you shouldn't write any sorting algorithm at all, right? because they are already implemented out there.
Oct 13, 2015 at 9:07 comment added JaDogg You do not really want to reinvent standard library functions because they are pretty nice optimized by c compiler -> Well said
Oct 13, 2015 at 8:26 history edited outoftime CC BY-SA 3.0
added 322 characters in body
Oct 13, 2015 at 7:43 history answered outoftime CC BY-SA 3.0