Answers for "double number java"

0

double number java

class doubleNumber{
	public static voidmain (String []args){
    int x = 40; // can be used to store whole numbers except decimals//
    double y= 40.4; // can be used to store all numbers including decimals//
    System.out.println(y/2);// will print out the result 20.2//
    System.out.println(x/2); // will print out 2//
    }
}
Posted by: Guest on February-27-2022

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language