45
kurosawa4434
23 44 60 Leader of the month
15782/ 17173
Awesome Team Masayuki Hayashi
Last seen 40 minutes ago
Member for 8 years, 1 month, 24 days
Difficulty Normal
Best reviews / Newest reviews
Binair Interpretation-Tinus_Trotyl 3 1
It's elegant solution :) I think that using 'str.maketrans()' is more readable. Line 13: for word in code.translate(str.maketrans('.-', '01')).split(' ')).capitalize() More
1-liner-Ylliw 1 1
I have almost the same idea, and you are better :-) More
Add turbo speed only for cases 12 < path < 21 and n == 5-Merzix 1 1
It is an interesting idea. But, How about the following case? assert g_key([[9, 9, 9, 9, 9], [9, 9, 9, 9, 9], [9, 9, 0, 0, 0], [9, 9, 0, 9, 9], [9, 9, 0, 9, 9]], 14) == 117 More
First-shankar294 1
good solution! and I try more simple ( line : 2-12 ) words = [(ord(w[0])-96)*10 + int(w[1]) for w in list(pawns)] More
First-vit.aborigen 1
directions = [v for v in permutations([-2, -1, 1, 2], 2) if (abs(v[0]) + abs(v[1]) == 3)] Good :-D The Manhattan-distance of knight's movement is always 3 with 5x5 grid. More
Short thanks to scipy.ndimage.label-Phil15 1 2
awesome solution. I used this solution to improve Visibility's `init.js`. More
Knapsack counter-HeNeArKr 1 1
Nice memoization. Line 30 equivalent the following: if not monster_ctr - lett_ctr: More
First, concentric hexagon check-Tinus_Trotyl 1 1
I thought of another expression of Line 20-23: for center in {a+b for a in A[radius: -radius] for b in B[radius: -radius]} - obstacles: check = center More
First-kurosawa4434 1
Thank you very much for checking my code! I feel the code is redundant. But this is the most I can do now. >PEP8 violations (long lines) Thanks, I will check PEP8. More
Borrowing ideas-HeNeArKr 1 1
It is an interesting idea. But, How about the following case? assert g_key([[9, 9, 9, 9, 9], [9, 9, 9, 9, 9], [9, 9, 0, 0, 0], [9, 9, 0, 9, 9], [9, 9, 0, 9, 9]], 14) == 117 More
Nice and documented solution with numpy-bsquare 1 1
good. Your result can be reduced. fix last code: return [int(n) for n in set(result) if result.count(n) % 2] More
First-ikaloveselina 1 1
nice solution. Python has a `defaultdict()` that has similar functionality to `append_to()`. from collections import defaultdict conn_hash = defaultdict(list) for a, b in lst: conn_hash[a].append(b) conn_hash[b].append(a) More
sum(1 for d in DIGITS if...)-evsistr 1 1
Nice solution. another way of Line 16-17 : a = sum(lit[0] <= set(d) <= (lit[0] | broken[0]) for d in DIGITS) b = sum(lit[1] <= set(d) <= (lit[1] | broken[1]) for d in DIGITS) More
The index dictionary-bravebug 1 1
This mission accepts iterable in its output. Line 39: return map(len, result) More
First-Pavellver 1 1
nice recursion. I forgot 'startswith'. Thank you. :) More
First_of_Halloween Monsters-Oleg_Novikov 1
Amazing speed! However, because of the greedy code, the random test fails with low probability. More
First-kurosawa4434
Thank you. Your code is elegant! More
Single loop-kudinov.feodor
I took a long time to understand. awesome ! More
First-kurosawa4434
Thank you! This code checking each pawn that have guards by using sets. More
First-kurosawa4434
Thank you! I did't know such a method. and find “Format specifications”. pt = format(pattern, '0'+str(len(command))+'b') More
1
2