public class MyClass {
public static void main(String args[]) {
byte b = 2;
System.out.println("Byte: " + b);
short s = 12;
System.out.println("short: " + s);
int i = 8782;
System.out.println("Integer: " + i);
long l = 94847;
System.out.println("Long: " + l);
float f = 3.14f;
System.out.println("Float: " + f);
double d = 9477234.987;
System.out.println("Double: " + d);
char ch = 'z';
System.out.println("Char: " + ch);
boolean bl = true;
System.out.println("Boolean: " + bl);
}
}
/*
run:
Byte: 2
short: 12
Integer: 8782
Long: 94847
Float: 3.14
Double: 9477234.987
Char: z
Boolean: true
*/