3 ms·
Simpler version, without having to parse HTML with regexes: >>> import lxml.etree, urllib2, hashlib >>> for a in lxml.etree.parse(urllib2.urlopen("http
by JoshTriplett 11y ago
Simpler version, without having to parse HTML with regexes:
>>> import lxml.etree, urllib2, hashlib
>>> for a in lxml.etree.parse(urllib2.urlopen("https://en.wikipedia.org/wiki/1956_in_film")).xpath("//a"):
... if a.text and hashlib.md5(a.text.strip().encode('utf-8')).hexdigest() == '0c9fc7b0723925183380b55e348462a9':
... print a.text
...
- dalke 11y agoDidn't have lxml installed. Or Beautiful Soup. "The best camera is the one you have with you." :)