57
veky
22 48 64 Leader of the month
44584/ 53887
Last seen 19 hours ago
Member for 11 years, 6 months, 6 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
Weak censorship-smilicic
`oneadd = True.__add__` is better. :-) More
multi-line oneliners-dshorstein 1
First, `from string import ascii_uppercase as lnums`. Second, why specialcasing digits? (string.digits + string.ascii_uppercase).index(digit, 0, radix) More
one line in each function-dshorstein 1
It always fascinates me when people see one line where I see four. :-D Anyway, first, doesn't this code duplication make you nervous? :-P Second, why general **kwargs when you only need key? def max(*args, key=None): ... More
took forever to discover iter()-mike-weinberg 1
How long will it take you to discover real keyword arguments? :-P def min(*args, key=lambda x: x): More
First-01011000
You don't need a comprehension. ''.join(ch for ch in text if ch.isupper()) More
First-jdrzaic
If you want both div and mod, there is no reason to do the work twice. :-) while number: number, digit = divmod(number, 2) ones += digit ((Of course, `bin(number).count('1')` is too simple.:)) More
For..in..for..in..for..in..foreign! Also, partial!-smilicic
The goggles, they do nothing! :-o Also, see [this](https://py.checkio.org/mission/colder-warmer/publications/veky/python-3/parentheses/share/ddd4befd4b0caa50d7008f47d3c64640/#comment-5463) comment as a demotivational poster. :-D More
First-abhisara
Wasn't it better, since you already made a copy in line 2, to destroy the copy (lines 7 and 10) than the original argument? :-) More
Do not understand how it done, but work well.-Pahkel
> Do not understand how it done Then how did you write it? :-) Especially I'm interested in that list(zip(...)) thing. I'm talking about exactly that in one of my VCRs. ;-] Also, didn't it occur to you to write just _one_ operation, and then iterate it in a loop instead of madly copy-pasting code More
First-SiLiKhon 3
Does np.array buy you anything at all? More
Thirteen-Melissa_Guzman
What's the contest: how to write it using a maximal number of lines? :-D More
3 strings for understanding-voloch
For understanding of what? Most convoluted way to solve this task? :-P Decorate-Sort-Undecorate is so 20th century. :-P More
Small and compact-olga.belykh 2
You have a weird definition of "small and compact". :-) More
Learning to keep it simple-carel.anthonissen 1
Aaargh. You remind me of Tom Petty, "Learning to fly (but I ain't got wings)". ;-9 More
Just count the quadrants-carel.anthonissen 1
Yup, count the quadrants. But it can be done much easier. See my solution. :-) More
First - Full enumeration-carel.anthonissen 1
return min(abs(...) for i in ... for c in ...) And that's it. :-) More
First - Brute force using recursion-carel.anthonissen 1
Argh. I _think_ you have the same algo as I do, only in about 10 times more lines. :-o More
Simple-luisfurnas
You use Python 3. Then _use_ it. :-) def min(*args, key=None): More
First - No surprises-carel.anthonissen 1
Meh... at least you could factor out e calculation (see my solution for single-case approach:). And since you're already importing math, was it so hard to tack on sqrt, too? :-) More
9 line solution-carel.anthonissen
You don't need to verify input represents real pawn configuration. :-) More