Hi.., happy new year after 3 months of gap i came here to post a powerful feature of java ,that is
multiple classes in a java program
Actually java is a programming language which it run in a platform.
1) Take three classes as
class a() { }
class b() { }
class multiple() {}
2)write program
3)compile ,after u will get
a.class , b.class ,multiple.class
multiple classes in a java program
Actually java is a programming language which it run in a platform.
1) Take three classes as
class a() { }
class b() { }
class multiple() {}
2)write program
3)compile ,after u will get
a.class , b.class ,multiple.class
PROGRAM CODE: save below code as multiple.java
class a
{
a()
{
int i=10;
System.out.println("value in class a="+i);
}
}
class b
{
b()
{
int i=5;
System.out.println("value in class b="+i);
}
}// no need to declare public access specifier
public class multiple
{
public static void main(String args[])
{
a A=new a();
b B=new b();
}
}
separately we code it asCLASS A()
class a { a() { int i=10; System.out.println("value in class a="+i); } }
CLASS B()
class b { b() { int i=5; System.out.println("value in class b="+i); } }
jianbin1205
ReplyDeletecheap uggs
north face outlet online
coach outlet online
uggs outlet
snapback hats
true religion outlet,true religion jeans,true religion kids,true religion jeans sale,true religion jeans for men,true religion jacket,true religion sale
cheap oakley sunglasses
moncler coats
ugg boots on sale
cyber monday
kobe bryants shoes 2015
polo ralph lauren uk
moncler outlet
lululemon outlet
prada outlet
chanel handbags
ugg uk outlet
toms outlet
canada goose outlet
the north face jackets
new england patriots
chicago blackhawks
michael kors outlet sale
new york giants
air force one shoes
nike air max 90
ugg boots
air jordan 11 free shipping
michael kors handbags
nike trainers uk
air jordan shoes
kansas city chiefs
chicago bulls