21
jmegner
5 22 34
2593/ 2695
Last seen 4 years ago
Member for 8 years, 11 months, 8 days
Difficulty Normal
I keep a repo of my solutions at: https://github.com/jmegner/CheckioPuzzles

Best reviews / Newest reviews
keep sets of which (r,c) points have right-segments and down-segments-jmegner
Whoops, this puzzle is from scientific expedition island, not elementary island. More
keep sets of which (r,c) points have right-segments and down-segments-jmegner
And I no longer need itertools! See github repo for [most recent version of the file](https://github.com/jmegner/CheckioPuzzles/blob/master/the-square-chest.py). More
First-ratkins7
your line of code matched my solution character-for-character; just so you know, someone else used a collections.Counter for a more efficient way to detect duplicates; More
First-Q-Bart
good use of list comprehension; someone else used collections.Counter for more efficient duplicate detection; Some style notes: 'i' is usually for indices, not elements; binary operators usually have spaces on both sides; More
First-yukirin
hard-to-understand one-liners are bad; break it up into named intermediate results More
First-dEUS
might want to use ord function rather than using straight ASCII values More
First-nastyajeid
You might like the collections.Counter class More
Maybe too long-icemourne66
just so you know, the sorted() built in function can take custom key functions so you can sort elements in custom ways for instance, sorted(numbers_array, key = abs) will sort the array using the abs function as the basis for sorting More
depth first search, make sure you don't block others, don't "bunch up" on your own path-jmegner
Takes a while on some of the tests where you have open areas for lots of path possibilities AND bottlenecks to cause trouble with most paths. Ideas for improvement that I hope to implement in future versions: * When checking if other paths are blocked, also do some smart force-move pathing to see More
Fleury's algo with simple connectedness checks to make Euler path-jmegner
Note: you'll see a lot of solutions that start at an odd-degree vertex and then travel to whatever adjacent vertex has the most untraveled edges remaining. I have a forum post detailing why I think that method is insufficient, and propose a test case to demonstrate the shortcoming of that method. More