Answers for "javascript how to compare numbers and return the highest"

0

greater number in arraya jd

var array = [3 , 6, 2, 56, 32, 5, 89, 32];
var largest= 0;

for (i=0; i<=largest;i++){
    if (array[i]>largest) {
        var largest=array[i];
    }
}




console.log(largest);
Posted by: Guest on May-28-2020
6

jsx return greatest number between two numbers

Math.max(5, 10);
Posted by: Guest on April-21-2020
0

javascript index of biggest number

arr.indexOf(Math.max(...arr))
Posted by: Guest on December-20-2019

Code answers related to "javascript how to compare numbers and return the highest"

Code answers related to "Javascript"

Browse Popular Code Answers by Language