43
kdim
17 43 60 Leader of the month
13161/ 14193
Dmitry Khromenko
Last seen 1 day ago
Member for 3 years, 4 months, 17 days
Difficulty Normal
I study Python myself and help my son and daughter learn programming.

Best reviews / Newest reviews
regexp-knezi 4
Good work! Also you can use flag "re.IGNORECASE" import re def checkio(words): return bool(re.search(r"[a-z]+ [a-z]+ [a-z]+", words, re.IGNORECASE)) More
4-liner: sum it up-Stensen 3
Also, len(str(num)) you can change to num > 9. More
mAlign-veky 3 1
"(op, *key), value in data" - cool! Your solution looks good! More
Using regex and max() with key-H0r4c3 2 1
You have a non-standard solution! More
find_divisors function-H0r4c3 2 1
Suitable place to use **yield** def find_divisors(n): for i in range(1, n): if n % i == 0: yield i More
First-dig 2 1
instead "total_time = datetime(2010, 1, 1, 1, 1, 1) - datetime(2010, 1, 1, 1, 1, 1)" you can use "total_time = timedelta()" More
One liner-amandel 1 1
pretty "num>0", otherwise nothing to add More
First-pandektis 1
also work: return not num % 2 More
First-pandektis 1 1
sorted(array, key=lambda x: (x[0], len(x))) before sorted - ['bac', 'aaaaa', 'av'] after sorted - ['av', 'aaaaa', 'bac'] Key as a function that returns a tuple (x[0], len(x)). The tuple values is different for different elements of array. '-' minus really works like reverse, this is a More
imtiaz.rahi's Pythonified-veky 1 1
abstruse, but very compact :-) More
Regex FTW!-H0r4c3 1 1
Good use of RE. Why didn't you use ''.join()? More
re.sub-eyes.in.head 1
interesting cobination - group(0).lower() More
Sorted and list comprehensions-r_tchaik 1
intresting construction =) - [item for item in items if item] More
First-kurosawa4434 1 1
Nice! Didn't you forget r''? '([^aeiouy ])[aeiouy]' More
First-Sim0000 1
Very good work, and nice solution! More
int to bin and maketrans in two lines-Olpag 1
h, m, s = ((int(n)//10, int(n)%10) for n in time_string.split(':')) Did well! More
Say what you want-veky 1 1
It's a very cool! You are Rock! More
Another Simple-danersow 1
str(num) - dont need, num is already string len(num.lstrip('0')) More
datetime-bravebug 1
a little shorter - lower().replace("m", ".m.") instead of - replace("AM", "a.m.").replace("PM", "p.m.") More
Too eager ;-)-veky 1 1
may be '%-I:%M %p' instead of lstrip('0')? More
1
2 3 4 5 6 7 8 9