Sort by domain name?

bearophileHUGS at lycos.com bearophileHUGS at lycos.com
Mon Oct 2 11:56:09 EDT 2006


js:
> All I want to do is to sort out a list of url by companyname,
> like oreilly, ask, skype, amazon, google and so on, to find out
> how many company's url the list contain.

Then if you can define a good enough list of such company names, you
can just do a search of such names inside each url.
Maybe you can use string method, or a RE, or create a big string with
all the company names and perform a longest common subsequence search
using the stdlib function. 

Bye,
bearophile




More information about the Python-list mailing list