How to find the maximum number in JavaScript

In JavaScript you can use the max() method that returns the number with the highest value.
You can use math.max function like as:
Math.max(number1, number2. . . ,numberN)
where number1, number2. . . ,numberN are the optional arguments If no arguments are given, the return result is -Infinity


     <title>How to use math.max in javascript</title></head>
           <script type="text/javascript" language="javascript">
                var MaxNum = Math.max(134,299,38,546);