32
martin_b
10 27 43 Leader of the month
5749/ 6195
Last seen 12 months ago
Member for 11 years, 6 months, 29 days
Difficulty Normal
Best reviews / Newest reviews
First-HeNeArKr 1
I think this is the pythonic way. Good work. More
First-sebastian.bramberger
Very short, does the job nicely, though kind of inefficient for real usage More
First-firevolk42
Some documentation of the algorithm would be helpful. More
First-Haskkor
Good algorithm. A comment explaining it would be helpful. More
Cyphy-HeNeArKr
Good work. However, there might be a bit more pythonic way to do it. For example, matrix rotation to right is reverse of rows followed by transpose, in python g = [list(l) for l in zip(*reversed(g))] More
Second-Blastus
It is questionable if the object oriented approach makes the code more readable in these small tasks. However, the main algorithm is IMHO a good choice, so overall good work. More
First-minto
I used almost the same approach, only with maps instead of lambdas, so obviously good work :-) More
ray casting-DaveDiFranco
Good code. Maybe a comment explaining the main idea (the point is inside if it intersects with odd number of edges) would be beneficial. More
First-ciel
The code is OK. However, I think it is much easier to keep the key as one string instead of slicing it to a list of strings. In that case the search for a character is one liner: x0, y0 = divmod(key.index(e[0]), 6). More
First-kurosawa4434
Some comments explaining the algorithm would be helpful. More
Using a stack for possible paths through pyramid-alexgerdom 1
The vote is for comments explaining the algorithm. However, the algorithm itself is not very efficient. A better algorithm is to go backwards from the bottom of the pyramid, always choosing the bigger of two values. More
I don't know an efficient way to determine upper case... Had to get clever with what I knew!-arthurheezen
I think it would be better to use ch.isupper() to test uppercase characters. More
First-blabaster
Some comment explaining the idea would be useful. More
using dict ?-sevaader
There is exclusive or operator x^y, which could be used instead of (x+y)%2 More
1 2
3