java.lang.Double.compareTo() java.lang.Double.compare() java.lang.Double.doubleToLongBits() java.lang.Double.compareTo() package com.codingdict; import java.lang.*; public class DoubleDemo { public static void main(String[] args) { // compares two Double objects numerically Double obj1 = new Double("8.5"); Double obj2 = new Double("11.50"); int retval = obj1.compareTo(obj2); if(retval > 0) { System.out.println("obj1 is greater than obj2"); } else if(retval < 0) { System.out.println("obj1 is less than obj2"); } else { System.out.println("obj1 is equal to obj2"); } } } java.lang.Double.compare() java.lang.Double.doubleToLongBits()