In Javascript, how do I check if an array has duplicate values?

前端 未结 3 1608
渐次进展
渐次进展 2020-11-28 03:39

Possible Duplicate:
Easiest way to find duplicate values in a javascript array

How do I check if an array has

3条回答
  •  难免孤独
    2020-11-28 04:04

    Well I did a bit of searching around the internet for you and I found this handy link.

    Easiest way to find duplicate values in a JavaScript array

    You can adapt the sample code that is provided in the above link, courtesy of "swilliams" to your solution.

提交回复
热议问题