2 レベルの深さの辞書があります。つまり、最初のディクショナリの各キーは URL であり、値は別のディクショナリであり、各キーは単語であり、各値はその URL に単語が出現した回数です。次のようになります。
dic = {
'http://www.cs.rpi.edu/news/seminars.html': {
'hyper': 1,
'summer': 2,
'expert': 1,
'koushk': 1,
'semantic': 1,
'feedback': 1,
'sandia': 1,
'lewis': 1,
'global': 1,
'yener': 1,
'laura': 1,
'troy': 1,
'session': 1,
'greenhouse': 1,
'human': 1
...and so on...
ディクショナリ自体は非常に長く、25 個の URL が含まれています。各 URL には、URL 内で見つかったすべての単語とその回数を含む別のディクショナリが値として含まれています。
辞書で最も異なる URL に含まれる単語を見つけたい。したがって、出力は次のようになります。
次の単語は y ページに x 回表示されます: 単語のリスト