Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.math.BigInteger;

public class Main {

    public static void main(String[] args) {

        // assign value to bi1
        BigInteger bi1 = new BigInteger("123");

        // assign a larger value to bi2
        BigInteger bi2 = new BigInteger("12345678");

        // assign double value of bi1, bi2 to d1, d2
        Double d1 = bi1.doubleValue();
        Double d2 = bi2.doubleValue();

        System.out.println(d1);
        System.out.println(d2);
    }
}