/*
class Parent{
private void method(){
System.out.println("Parent");
}
public static void main(String args[]){
Parent p=new Parent();
Child c=new Child();
Parent d;
d=c;
p.method();
c.method();
d.method();
System.out.println("c="+c+" d="+d);
}
}
class Child extends Parent{
public String method(){
System.out.println("Child");
return "result";
}
}
*/
Can someone explain how we can call c.method() without assigning return value (String) to some variable?