Here you can find the source of max(Number num1, Number num2)
public static Number max(Number num1, Number num2)
//package com.java2s; //License from project: Apache License public class Main { public static Number max(Number num1, Number num2) { return (num1.doubleValue() > num2.doubleValue()) ? num1 : num2; }//from w w w .ja va 2 s . co m }