Solved

Identify a Compare Function That Sorts Numeric Values in Ascending

Question 68

Multiple Choice

Identify a compare function that sorts numeric values in ascending order.


A) ​function ascending(a,b) {
Return a - b;
}
B) ​function ascending(b,a) {
Return a;
}
C) ​function ascending(a,b) {
Return b - a;
}
D) ​function ascending(b,a) {
Return b;
}

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions