Re:Show HN: Available .com's in /usr/share/dict/words
by addandsubtract on Saturday March 08, 2014 @03:58PM
(#7366374)
You seem to be counting \0 as a char, or meant to find words less than 7 chars. Either way, there are just over 100 names available with 7 chars.
Re:Show HN: Available .com's in /usr/share/dict/words
by adamcanady on Saturday March 08, 2014 @04:11PM
(#7366407)
Probably counting \n as a character since Python is pretty good about never dealing with \0's.
with open('domains.txt') as domains: for line in domains: if len(line) < 8: print line
befogs
cagily
dourer
drolly
gusted
livia
lorded
neglig
scrods
shirrs
soughs
tyroes
unmans
unsays
vilyui