Inheritance in java
https://cjavapoint.blogspot.com/?m=1
https://cjavapoint.blogspot.com/?m=1
Multiple Inheritance in Java
https://cjavapoint.blogspot.com/?m=1
https://cjavapoint.blogspot.com/?m=1
*Static Nested Class*
1) Static Nested ClassIn java static nested class is a class which is defined in a class with static keyword.
static nested class cannot access non-static data member and methods of outer class. It can access only static data member of outer class including private.
Java Static Nested Class Example
class Simple
{
static int a = 700;
static class SimpleInner
{
void show()
{
System.out.println("value is"+a);
}
}
public static void main(String args[])
{
Simple.SimpleInner s = new Simple.SimpleInner();
s.show();
}
}
https://cjavapoint.blogspot.com/?m=1
1) Static Nested ClassIn java static nested class is a class which is defined in a class with static keyword.
static nested class cannot access non-static data member and methods of outer class. It can access only static data member of outer class including private.
Java Static Nested Class Example
class Simple
{
static int a = 700;
static class SimpleInner
{
void show()
{
System.out.println("value is"+a);
}
}
public static void main(String args[])
{
Simple.SimpleInner s = new Simple.SimpleInner();
s.show();
}
}
https://cjavapoint.blogspot.com/?m=1
Blogspot
Core Java Interview Questions - Learn Java
Java Tutorial or Learn Java or Core Java Tutorial or Java Programming Tutorials for beginners and professionals with core concepts and examples
👍1