10.6 You have 10 billion URLs. How do you detect the duplicate documents? In this case, assume that "duplicate" means that the URLs are identical. 这道题让我们在一百亿个URL链接中寻找相同项,看这数据量简直吓尿了,如果每个URL链接平均100个字符的话,每个字符是4个字节,那么总共需要占4TB的空间,我们无法在内存中导入这么大的数据量.假如
// 获取url中的参数,并返回一个对象 $.getRequestData = function() { var url = location.search; //获取url中"?"符后的字串 var theRequest = {}; if (url.indexOf("?") != -1) { var str = url.substr(1); strs = str.split("&"); for (var i = 0; i < st