11
arma
1 11 20
556/ 645
Last seen 4 years ago
Member for 10 years, 2 months, 5 days
Difficulty Normal
Playing Python

Best reviews / Newest reviews
recursion-Cjkjvfnby 2 1
Very original recursion solution. This technique is described here: [Extended Iterable Unpacking](https://www.python.org/dev/peps/pep-3132/) It's unique Python3 feature: https://docs.python.org/3/whatsnew/3.0.html#new-syntax More
try, except-Aaglacrinus
The only drawback here is that it catches ALL exceptions (which is considered as bad practice), while it's better to catch specific exception type. https://docs.python.org/2.7/howto/doanddont.html#except More
Map & Filter & Reduce fun-arma
All functional programming zoo is here for fun :) More
Any permutation-FlorisLambrechts
Nice one-liner. Using _True_ instead of _(a,b)_ might look cleaner: any(True for a, b in permutations(words_set, 2) if a.endswith(b)) More
Python's Forgiveness vs. Permission-arma
Illustrates Python principle: "**It's easier to ask for Forgiveness than Permission**" (EAFP). This differs how we usually write the code in other programming languages (C, Java, PHP, Ruby, etc) with many condition checks, if-else statements. https://docs.python.org/2/glossary.html#term-eafp More
First-lyyljs
Pretty clear one. You can also simplify first 3 lines with: nets = list(set(net.split('-')) for net in network) More
class Rings() w algo explained-arma
No brute-forcing or combinations, but long More
Predefined rules in OrderedDict-arma
it should be just `tuple` instead of `OrderedDict` More
First-furas
You could avoid creating additional `t` variable and just: for x in text.lower(): ... More