public class Main {
public static void main(String[] args) {
Double dObj = new Double("10.50");
byte b = dObj.byteValue();
System.out.println(b);
short s = dObj.shortValue();
System.out.println(s);
int i = dObj.intValue();
System.out.println(i);
float f = dObj.floatValue();
System.out.println(f);
double d = dObj.doubleValue();
System.out.println(d);
}
}
/*
10
10
10
10.5
10.5
*/
|