> I need help writing a JavaScript code.?

I need help writing a JavaScript code.?

Posted at: 2014-12-18 
Here is the assignment: write a JavaScript function that is called compare that takes in two paramaters, both numbers, and returns the number greater of the two numbers.

function compare(num1, num2) {

????return Math.max.apply(Math, arguments);

}

Here is the assignment: write a JavaScript function that is called compare that takes in two paramaters, both numbers, and returns the number greater of the two numbers.