April 24, 2018, 11:58 a.m. |
+ 1 |
for Comment
jtokaz: Good. Since "len(set(elements))>1" is a bool you can return it directly. You could return "not len(s...
|
April 17, 2018, 6:12 a.m. |
+ 1 |
for Comment
kurosawa4434: It's elegant solution :) I think that using 'str.maketrans()' is more readable. Line 13: for word in...
|
April 14, 2018, 6:42 p.m. |
+ 1 |
for Comment
jtokaz: Python has slicing similar to Matlab, e.g. array[::2]. Also in Python, any object can be tested for ...
|
April 2, 2018, 4:11 p.m. |
+ 1 |
for Comment
StefanPochmann: You [reinventor](https://github.com/python/cpython/blob/de7a2f04d6b9427d568fcb43b6f512f9b4c4bd84/Obj...
|
March 28, 2018, 12:09 p.m. |
+ 1 |
for Comment
StefanPochmann: Yeah, I saw that. It's one of the reasons for hiding it in "Uncategorized" :-)
|
March 23, 2018, 2:06 p.m. |
+ 1 |
for Comment
narimiran: Not nearly enough cases.... See [here](https://py.checkio.org/mission/fizz-buzz/publications/jesaisp...
|
March 23, 2018, 2:05 p.m. |
+ 1 |
for Comment
loonydevil: damn, you're my hero :)
|
March 22, 2018, 3:40 p.m. |
+ 1 |
for Comment
flpo: Hi & thanks for the compliment! Sure, first at all you should consider that ["The set of all Turing ...
|
March 22, 2018, 3:39 p.m. |
+ 5 |
for
shortest solution factorized-flpo
|
March 22, 2018, 3:38 p.m. |
+ 3 |
for
recursive-flpo
|
March 22, 2018, 3:36 p.m. |
+ 3 |
for
First-Tinus_Trotyl
|
March 19, 2018, 3:25 p.m. |
+ 1 |
for Comment
veky: "<=1" was too much to ask? :-P
|
March 16, 2018, 3:49 p.m. |
+ 2 |
for
A small trick-cutekibry
|
March 16, 2018, 3:45 p.m. |
+ 2 |
for
First-omikojangebashvili
|
March 15, 2018, 3:43 p.m. |
+ 1 |
for Comment
bryukh: Do you know what `set` data type is?
|
March 15, 2018, 3:14 p.m. |
+ 1 |
for
Best Speeches of Mr. Hettinger. Part 1
|
March 10, 2018, 9:33 p.m. |
+ 3 |
for
Japanese-Sim0000
|
March 5, 2018, 10:02 a.m. |
+ 5 |
for
First-Moff
|
March 5, 2018, 9:58 a.m. |
+ 1 |
for Comment
veky: Why not simply "return l == list"? Lists are equal, not only their lengths.
|
March 2, 2018, 12:31 p.m. |
+ 3 |
for
First-vadim-job-hg
|
March 1, 2018, 6:06 p.m. |
+ 1 |
for Comment
Sim0000: I think this is a bit overkill. I think this task has too many exceptions and is not fun. At least, ...
|
March 1, 2018, 2:52 p.m. |
+ 1 |
for Comment
Brda: Wow!! if array: return sum(array[::2]) * array[-1] else: return 0
|
March 1, 2018, 2:52 p.m. |
+ 1 |
for Comment
Brda: Wow again!! How deep Python is!! return sum(array[::2]) * array[-1] if array else 0
|
Feb. 27, 2018, 7:23 p.m. |
+ 1 |
for Comment
veky: Of course. The main criterion for including something in the Python stdlib is that the algorithm is ...
|
Feb. 27, 2018, 7:20 p.m. |
+ 5 |
for
convert into regex-kurosawa4434
|
Feb. 27, 2018, 6:50 p.m. |
+ 2 |
for
Best Stock-Rolex
|
Feb. 27, 2018, 6:41 p.m. |
+ 1 |
for Comment
Tinus_Trotyl: Whow . . . NICE . . . ! ! ! You did what I looking for (connecting an logical output value to add/di...
|
Feb. 27, 2018, 4:51 p.m. |
+ 5 |
for
Using difflib-macfreek
|
Feb. 27, 2018, 4:51 p.m. |
+ 1 |
for Comment
macfreek: Why reinvent the wheel? https://docs.python.org/3/library/difflib.html#difflib.SequenceMatcher.find_...
|
Jan. 17, 2018, 11:12 a.m. |
+ 2 |
for
get-DahliaSR
|
Jan. 11, 2018, 10:09 p.m. |
+ 5 |
for
My favorite way of solving oduvan's missions :-P-veky
|
Jan. 9, 2018, 10:49 p.m. |
+ 1 |
for Comment
DahliaSR: Same! :D
|
Jan. 3, 2018, 3:47 p.m. |
+ 1 |
for Comment
Tinus_Trotyl: **HEY, COOL :-)** Some more number facts: 2018 = 2 (prime) x 1009 (prime) 2 + 0 + 1 + 8 = 11 (prime)...
|
Jan. 3, 2018, 3:47 p.m. |
+ 1 |
for Comment
Sim0000: Happy new year. 2018 is the sum of squares of 12 consecutive numbers. **sum((7+i)\*\*2 for i in rang...
|
Jan. 1, 2018, 9:06 a.m. |
+ 1 |
for Comment
DahliaSR: Nice. Using _itertools.isslice()_, instead of slice notation, would also decrease the auxiliary spac...
|
Dec. 20, 2017, 8:14 a.m. |
+ 1 |
for Comment
Sim0000: I use it to avoid flags when I find something. for loop-condition: ... if some-condition: break ... ...
|
Dec. 6, 2017, 9:32 p.m. |
+ 1 |
for
Golf-Ylliw
|
Dec. 6, 2017, 9:27 p.m. |
+ 1 |
for Comment
flpo: I think you can start your research from these :) https://bugs.python.org/issue1660179 https://bugs....
|
Nov. 28, 2017, 3:16 p.m. |
+ 1 |
for Comment
hanpari: What about left side slides for inplace replacement? listy = list(range(7)) listy[:3] = 0, 0, 0 list...
|
Nov. 24, 2017, 8:21 a.m. |
+ 1 |
for Task
Barcode Reader
|
Nov. 21, 2017, 9:09 p.m. |
+ 1 |
for Comment
flpo: Thanks! Nice codegolfish, but in that case I'd rather to spend a single more char but keep consisten...
|
Nov. 19, 2017, 1:28 p.m. |
+ 3 |
for
Second Composition of Functions-flpo
|
Nov. 19, 2017, 1:16 a.m. |
+ 1 |
for Post
mission idea "Barcode Reader"
|
Nov. 18, 2017, 2:33 p.m. |
+ 1 |
for Comment
flpo: Hi, I know that this is a creative solution but the positional argument inside the string are simply...
|
Nov. 17, 2017, 9:03 p.m. |
+ 1 |
for Comment
StefanPochmann: Lol... so reply-by-email does work, and really does allow me to give +5, instead of just +1 like I c...
|
Nov. 15, 2017, 5:10 p.m. |
+ 1 |
for Comment
veky: Next time someone tells me Python is a functional programming language, I'll show them this. :-DD
|
Nov. 15, 2017, 5:06 p.m. |
+ 3 |
for
Say Hi-svartmetall
|
Nov. 13, 2017, 12:15 a.m. |
+ 2 |
for
2-liner: no import, based on gyahun_dash's solution-przemyslaw.daniel
|
Nov. 13, 2017, 12:06 a.m. |
+ 1 |
for Comment
przemyslaw.daniel: This one is ok and deserves to be in clear category. It could be made a little bit shorter by using ...
|
Nov. 12, 2017, 2:17 p.m. |
+ 1 |
for Comment
veky: Yup. For homework, meditate on the difference between *a, = b and a = *b, ;-D
|
Nov. 7, 2017, 11:21 p.m. |
+ 2 |
for
Balanced-R2R
|
Nov. 5, 2017, 6:27 p.m. |
+ 1 |
for Comment
veky: > Python itself doesn't have a native array data structure Where do you get such ideas? `array.array...
|
Oct. 17, 2017, 10:41 p.m. |
+ 1 |
for Comment
veky: Seriously, no mention of printing an output instead of returning it from a function? It's easily hal...
|
Oct. 14, 2017, 4:42 p.m. |
+ 1 |
for Comment
przemyslaw.daniel: +1 for perfect obfuscation of such a simple task :-)
|
Oct. 14, 2017, 8:35 a.m. |
+ 1 |
for Comment
veky: Both of them use `__slots__` in order to prevent namedtuple-inherited classes to acquire a `__dict__...
|
Sept. 30, 2017, 8:55 a.m. |
+ 1 |
for Comment
veky: ROTFL. C-argo C-ult, in a way. :-D
|
Sept. 27, 2017, 7:54 a.m. |
+ 1 |
for Comment
hrvoje: Very cool use of string.join('()'). It does remind of a female body part, though. Naughty Veky. :)))
|
Sept. 26, 2017, 6:52 p.m. |
+ 2 |
for
GroupBy-frantisek.jahoda
|
Sept. 4, 2017, 3:43 p.m. |
+ 1 |
for Comment
veky: I know what happens there, of course. I don't know what "it doesn't work like this" means. :-P So, w...
|
Aug. 16, 2017, 6:57 a.m. |
+ 1 |
for Comment
veky: Here's more about [Py3](https://py.checkio.org/mission/weak-point/publications/veky/python-3/factore...
|
July 28, 2017, 8:42 a.m. |
+ 1 |
for Comment
ciel: I also thought this was an educational mission, but recent twisted test case has made this less educ...
|
July 2, 2017, 10:26 p.m. |
+ 1 |
for Post
stressful subject
|
July 2, 2017, 7:25 a.m. |
+ 1 |
for Comment
veky: Your definition "List is completely empty when all list inside of this list are empty." is in fact w...
|
June 30, 2017, 8:52 p.m. |
+ 1 |
for Comment
veky: > Default “Clear” category means that you share clean and well written code that is easy to read. No...
|
June 27, 2017, 7:34 p.m. |
+ 1 |
for Post
New Mission "Completely Empty"
|
June 27, 2017, 7:32 p.m. |
+ 1 |
for Task
Completely Empty
|
June 27, 2017, 7:24 p.m. |
+ 1 |
for Post
New Mission "Cut Sentence"
|
June 24, 2017, 8:47 a.m. |
+ 1 |
for Comment
PythonWithPI: I tried to do this, but it wasn't working. Good solution!
|
May 23, 2017, 8:21 a.m. |
+ 1 |
for Comment
veky: Of course. You would get more thumbs if you imported from stdlib. ;-]
|
May 23, 2017, 8:19 a.m. |
+ 2 |
for
Using Heron's formula and sines law-rchmielarz
|
May 10, 2017, 11:18 a.m. |
+ 1 |
for Comment
veky: "Pythonic" is not the same as "should be part of Python stdlib". There are many perfectly Pythonic p...
|
May 9, 2017, 4:33 p.m. |
+ 1 |
for Comment
veky: Of course. I just said, if you already have a lambda, why not have another? :-)
|
May 8, 2017, 5:09 p.m. |
+ 1 |
for Comment
veky: Since so many people here adore your solution, I won't spend too much words about how beautiful it i...
|
May 7, 2017, 4:01 p.m. |
+ 1 |
for Task
Open Labyrinth
|
May 7, 2017, 3:48 p.m. |
+ 2 |
for
Stressful Regex-narimiran
|
May 7, 2017, 1:28 p.m. |
+ 1 |
for
First-McTpaxep
|
May 7, 2017, 12:39 p.m. |
+ 1 |
for Comment
veky: Worth liking, maybe. In a "Clear" category, no. Anyway, there is a way to avoid resorting: you just ...
|
May 5, 2017, 8:03 a.m. |
+ 1 |
for Comment
veky: Thanks. Many people forget Python has native support for complexes. I program for about 30 years, an...
|
May 3, 2017, 7:55 a.m. |
+ 2 |
for
String multiplication-PierreLejeail
|
May 3, 2017, 7:49 a.m. |
+ 1 |
for Comment
narimiran: Instead of defining the lambda function for a key, there's a simpler solution that serves the same p...
|
May 3, 2017, 7:48 a.m. |
+ 1 |
for Comment
narimiran: There are several things that can be learnt/improved here: 1. I already mentioned in one other your ...
|
May 1, 2017, 6:21 p.m. |
+ 1 |
for Task
New Cities
|
April 25, 2017, 5:20 p.m. |
+ 1 |
for Post
IDEA: Do we need Python 2.7?
|
April 22, 2017, 10:40 a.m. |
+ 1 |
for Comment
veky: The last solution has no place in hints. Please don't promote filtering lambdas. Generator expressio...
|
April 19, 2017, 11:35 p.m. |
+ 1 |
for Comment
DahliaSR: Clear! You can improve your solution by apllying the [EAFP coding style](https://docs.python.org/3/g...
|
April 16, 2017, 11:28 p.m. |
+ 1 |
for Comment
DahliaSR: Very complicated and lots of redundant expressions. - Line 12: a = n What for? You are not reusing t...
|
April 12, 2017, 4:31 p.m. |
+ 1 |
for Comment
DahliaSR: `[i for i in range(-10, 10)]`: this is a list-comprehension and resturns a list `(abs(i) for i in ra...
|
April 7, 2017, 9:34 p.m. |
+ 1 |
for Task
Node Disconnected Users
|
March 28, 2017, 1:46 p.m. |
+ 5 |
for
Exception mishandling-veky
|
March 11, 2017, 11:52 a.m. |
+ 1 |
for Comment
kadir.dmr: shuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuu
|
March 11, 2017, 11:52 a.m. |
+ 1 |
for Comment
jannidis: (1), (2) and (5) and (7): important libraries like numpy or pandas etc.
|
March 11, 2017, 11:52 a.m. |
+ 1 |
for Comment
shaunanderson5: I would like to see some missions that are more helpful for the beginner programmer, the concept ser...
|
March 11, 2017, 11:52 a.m. |
+ 1 |
for Comment
jocow: I would like to see more architectural missions ? See my other posts related to this
|
March 11, 2017, 11:52 a.m. |
+ 1 |
for Comment
Sulverus: I would like to see problems about distributed algorithms: gossip, paxos, raft
|
Feb. 28, 2017, 8:57 a.m. |
+ 1 |
for Comment
veky: Whenever you try to write some new functionality, stop. And think, of the enormous number of Pythoni...
|
Feb. 28, 2017, 8:57 a.m. |
+ 1 |
for Comment
kot0begemot: Wow, you just reinvented a bicycle! :) There is a built-in int() in Python that can use radix as a s...
|
Feb. 11, 2017, 4:10 p.m. |
+ 1 |
for Comment
veky: BTW Tangentially relevant: https://pbs.twimg.com/media/CouOwSdW8AAXrkF.jpg:large ;-D
|
Feb. 9, 2017, 11:17 p.m. |
+ 1 |
for Comment
ned2: For each element in data it does element.count(), which requires a sequential scan of the whole inpu...
|
Jan. 31, 2017, 12:45 p.m. |
+ 1 |
for
Python Bruteforces
|
Jan. 28, 2017, 4:54 p.m. |
+ 1 |
for
You can create missions again
|