http://aset.its.psu.edu/announcements/newsgroup_changes.html
http://aset.its.psu.edu/unix_group/
http://aset.its.psu.edu/unix_group/unixaccounts.html
http://aset.psu.edu/ait/
http://aset.psu.edu/ait/filesys.html
http://aset.psu.edu/unix_group/lsfaqs.html
http://aset.psu.edu/unix_group/quickunix.html
http://cac.psu.edu/
http://cac.psu.edu/publish/htpasswd/alternate.html
http://clc.its.psu.edu/
http://clc.its.psu.edu/Labs/
http://clc.its.psu.edu/Labs/Mac/
http://clc.its.psu.edu/labs/Mac/software/all.aspx
http://clc.its.psu.edu/labs/Mac/software/default.aspx
http://css.its.psu.edu/internet/
http://css.its.psu.edu/internet/unix.html
http://css.its.psu.edu/news/alerts/
http://css.its.psu.edu/news/alerts/K4notice.html
http://its.psu.edu/
http://its.psu.edu/computing.html
http://its.psu.edu/learning.html
http://search.psu.edu/query.html
...is sorted by current algorithm (in OP) in the following desired order...
http://aset.psu.edu/ait/
http://aset.psu.edu/ait/filesys.html
http://aset.psu.edu/unix_group/lsfaqs.html
http://aset.psu.edu/unix_group/quickunix.html
http://cac.psu.edu/
http://cac.psu.edu/publish/htpasswd/alternate.html
http://aset.its.psu.edu/announcements/newsgroup_changes.html
http://aset.its.psu.edu/unix_group/
http://aset.its.psu.edu/unix_group/unixaccounts.html
http://clc.its.psu.edu/
http://clc.its.psu.edu/Labs/
http://clc.its.psu.edu/Labs/Mac/
http://clc.its.psu.edu/labs/Mac/software/all.aspx
http://clc.its.psu.edu/labs/Mac/software/default.aspx
http://css.its.psu.edu/internet/
http://css.its.psu.edu/internet/unix.html
http://css.its.psu.edu/news/alerts/
http://css.its.psu.edu/news/alerts/K4notice.html
http://its.psu.edu/
http://its.psu.edu/computing.html
http://its.psu.edu/learning.html
http://search.psu.edu/query.html
...sorting is done first on the 2d level TLD, then on hostname if
any, then on the remaining string if any. (I thought i already
wrote that in OP; perhaps was not clear...)
Lest we forget the question, is there a less verbose way
(than the one in OP) to sort the URLs on criteria just presented
above?
(Long) Side note: FWIW, i converted the given Schwartzian transform
to Gottman-Rosler Transform as an exercise, which was faster around 14-16%
(benchmarked, Perl 5.8, merge/quick sorts, FreeBSD 4.7/386)
-- not much of a difference (to me in this case, unless i am missing
something).
|