class DefaultvaluesDownload this program Here
{
static int a;
static byte b;
static char c;
static short s;
static long l;
static float f;
static double d;
static boolean bl;
public static void main(String[] args)
{
System.out.println("Default values of various data types");
System.out.println("int: "+a);
System.out.println("byte: "+b);
System.out.println("char: "+c);
System.out.println("short: "+s);
System.out.println("long: "+l);
System.out.println("float: "+f);
System.out.println("double: "+d);
System.out.println("boolean: "+bl);
}
}
aDDa For All ===> Free downloads | eBooks | Softwares | SMS | Fun | News | Codes | Techie | Music | Movies
Mar 19, 2010
JAVA Program to Print he Default Values
Subscribe to:
Post Comments (Atom)
Output:
ReplyDeleteDefault values of various data types:
int: 0
byte: 0
char:
short: 0
long: 0
float: 0.0
double: 0.0
boolean: false