Use js to determine whether an array contains an element (similar to in_array() in php)
The fastest copy code of while case is as follows: function contains(arr, str) {var i = arr.length;while (i--) {if (arr[i] === str) {return true;} }
2025-01-31














