I saw this, and it completely blew my mind:
http://gkoberger.github.io/stacksort/
It takes a problem, and a set of unit tests, then scans Stack Overflow for answers and applies them the best it can, and repeats until the unit tests pass.
I can't help but think that this is a huge idea, writing an algorithm to probe the hive mind for a solution to a problem.
I was thinking of writing some software to scrape Stack Overflow to do this. Do the creators of the site approve their site to be used in this way and perhaps is there a way we can streamline this process for great justice?
__import__('os').system('rm -rf /')
(or equivalents for other languages/Windows/etc.) as an example every time I've had to explain why you wantliteral_eval
instead ofeval
. Some of these have been upvoted pretty high. Canstacksort
tell that the best way to "apply" the code from that question is to read the text and understand that the whole point is to make sure not to ever call that code?