$define RCLANGS "http://rosettacode.org/mw/api.php?format=xml&action=query&generator=categorymembers&gcmtitle=Category:Programming%20Languages&gcmlimit=500&prop=categoryinfo" $define RCUA "User-Agent: Unicon Rosetta 0.1" $define RCXUA "X-Unicon: http://unicon.org/" link strings link hexcvt procedure main() cnt := create seq() last := -1 every pair := !reverse(sort(langs := tallyPages(),2)) do { n := if last ~=:= pair[2] then @cnt else (@cnt,"") write(right(n,4),": ",left(pair[1],30,". "),right(pair[2],10,". ")) } write(*langs, " languages") end # Generate page counts for each language procedure tallyPages(url) /url := RCLANGS counts := table() continue := "" while \(txt := ReadURL(url||continue)) do { txt ? { if tab(find("gcmcontinue=")) then { continue := "&"||tab(upto('"')) move(1) continue ||:= tab(upto('"')) } else continue := "" while tab(find("