Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
mudbungie
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
4 ms
·
1.
▲
by
mudbungie
10y ago
I like your solution! Good use of iter(). You actually bring up an interesting question of design philosophies. I thought that the script that I posted was extremely explicit, and therefore clear. Yours is far more terse, and implicit, whic
2.
▲
by
mudbungie
10y ago
Yeah, I wrote that after staring at it for a few minutes, and giving up any pretense that I could model it with confidence.
3.
▲
by
mudbungie
10y ago
Actually, line 46 is referencing the class Girl, so you wouldn't want quotes. Technically, you're supposed to use try/except duck-typing in Python, but I often find that clearer code comes out of assertions where you literall
4.
▲
by
mudbungie
10y ago
I chose to answer the question empirically. http://pastebin.com/1g1bAEPt Turns out it's equal.