What will be the output of the following JavaScript code? [code] <p id="demo"></p> <script> var numbers = [45, 4, 9, 16, 25]; var arr=

What will be the output of the following JavaScript code?
Code:
<p id="demo"></p>
<script>
var numbers = [45, 4, 9, 16, 25];
var arr= numbers.every(myFunction);
document.getElementById("demo").innerHTML =arr;
function myFunction(value, index, array) 
{
   return value > 18;
}
</script>
A. true
B. false
C. 0
D. error
 

Tìm kiếm

Back
Top