Home
last modified time | relevance | path

Searched refs:isPrime (Results 1 - 3 of 3) sorted by relevance

/arkcompiler/ets_runtime/test/moduletest/arrayFindIndexCase/
H A DfindIndex.js35 function isPrime(element) { function
46 print([4, 6, 8, 9, 12].findIndex(isPrime));
47 print([4, 6, 7, 9, 12].findIndex(isPrime));
/arkcompiler/ets_runtime/test/moduletest/arrayfind/
H A Darrayfind.js43 function isPrime(element, index, array) { function
53 console.log([4, 6, 8, 12].find(isPrime));
54 console.log([4, 5, 8, 12].find(isPrime));
/arkcompiler/ets_runtime/test/moduletest/arrayFilterCase/
H A DarrayFilterCase.js62 function isPrime(num) { function
71 print(array.filter(isPrime)); // [2, 3, 5, 7, 11, 13]
100 print(emptyArr.filter(isPrime).length);

Completed in 2 milliseconds