Online Java Compiler By
JavaTpoint.com
public class Double_doubleToLongBitsMethod_Example2 { public static void main(String[] args) { //passing negative value double d1=-65876856.6756756; Double d2= new Double(d1); //Converting negative double to long Bits System.out.println(d1+" value in long bits = "+Double.doubleToLongBits(d2)); } }
Output