57
veky
22 48 64 Leader of the month
44668/ 53887
Last seen 11 hours ago
Member for 11 years, 6 months, 24 days
Difficulty Advanced
We shall not cease from exploration, and the end of all our exploring will be to arrive where we started and know the place for the first time.

Best reviews / Newest reviews
BrailleTranslator-bunnychai 1
Very mathematical solution. :-D More
First-matsumoto-shingo-z02 1 1
Lines 22~31 are a crime against humanity. Or at least they should be. ;-P size = sum(1 + c.isupper() + c.isdigit() for c in text) More
Magnum opus-veky 1 3
* Note the smiley at the end of line 1. ;-) * Find how many Python keywords are in the essay. ;-) * What's the connection between 73 and CheckiO (for old ones here;)? More
It can take negative indexes too-borisuvarov 1 1
... except if array is empty, then it cannot. ;-D More
oneliner-tivvit 1
Instead of lambda with \*, you can use `operator.mul`. Or if you don't want to import one module more, you can use `int.__mul__`. int(z) is duplicated, since this is the reverse of usual listcomp paradigm: you need map first, then filter over that. So you can use the building blocks directly. More
First-fishiwhj 1 1
Line 18 is wrong. rounded gamma is _not_ necessarily equal to 180 - rounded alpha - rounded beta. BTW why do you reinvent the wheel (in this case, builtin round function)? More
Simple but a bit verbose-UndeadMonkey 1
First, line 5 is if not array: Second, sum is a builtin. You don't have to maintain it manually. Third, indexing from range is just a slice. array[::2]. More
Pigeons with explaination-UndeadMonkey 1
Lines 20~23 are really just one line. Hint: min. Please don't print(str(corn) + " corn is left"). Do print(corn, "corn is left") print is smart enough to strify automatically, and even to put a space between. ;-) Lines 2~3: pigeons = minute = 1 More
First-pohmelie 1 1
Line 25 is head-scratching. Sometimes comprehension is the best option. edges = {(s[:2], s[2:]) for s in segments} By the same token, len(tuple(filter(lambda c: counts[c] % 2, counts))) is len([c for c in counts if counts[c]%2]) or even better sum(v%2 for v in counts.values()) iter More
First-UndeadMonkey 1
numstring is semantically empty, str(number) says the same thing in a clearer way. You could even iterate for digit in map(int, str(number)): You don't need != 0 in line 7: if digit: answer *= digit More
The meaning of life-Sisyphus 1 1
... Universe, and everything. Who has actually run this and expected to see 54? :-D More
First-michael.kej 1
You don't need to import date. ;-) You can just say timedelta(1). diff is a strange name for what you're really calculating. "in {5, 6}" is probably nicer than "in [5, 6]". Or just > 4. :-) Line 4 is O_O. :-P More
First - Building Base-AQiccl135 1 1
You don't need (object) in line 1. Initializing of self.corner_dict is really strange. Why not just return a dict literal? repr can be much clearer with {0.s}, {0.w} and so on, .format(self). comments above methods really should be docstrings. volume can reuse area calculation. More
defaultdict-Sim0000 1
Yes, this is much nicer. That ugly last line indexing, it could have been just d[max(d)], right? :-) More
21-liner: first proposal with no bechmarks-przemyslaw.daniel 1
You're reinventing [the wheel](https://docs.python.org/3.9/library/heapq.html#heapq.nlargest). More
17<<16-veky 1
Of course, sys.maxunicode would be much more clear, if only CiO weren't so paranoid. :-P More
double updown - no imports-juestr 1
yes, it's nive that in absence of zeros, two first ducks are in fact the same. 🦆😅 More
it's a python the way? ;)-kdim 1
'ddott' cracked me up. :-D But really, is this supposed to be in the "clear" category? :-] Also: for callback in d.values(): time = callback(time) More
First-Juge_Ti 1
angles really could have been a list of dicts, not of tuples. At least namedtuples. angles[1][0] just seems incredibly unpythonic to me. :-) And you could have imported radians from math, it would help readability of your radians function. 648000 is a really magic number, it only reminds me of "648 More
cheat \^.^/-bunnychai 1
Many other cheats are possible. See my solution for possibilities. :-) More