本人较懒,直接将链接附上: JavaScript下去重算法优化:http://www.linuxde.net/2013/02/12062.html 转载于:https://www.cnblogs.com/lycnblogs/p/4905077.html