Double class Constructor

Double(double value)Creates a Double object that represents the primitive double argument.
Double(String s)Creates a Double object that represents the double value represented by the string.

public class Main {
  public static void main(String[] args) {
    System.out.println(new Double(1.1));
    System.out.println(new Double("1.2"));


The output:

1.2  |  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.