class A{ void me(){s.o.p("");} class B extends A{ void me()
{s.o.p(" ");} class M{ A a=new B(); B b=new A(); a.me();
b.mne();} what is the output of this, how?
Answers were Sorted based on User's Feedback
Answer / kay
class A
{
public virtual void me()
{ s.o.p(" hi");
}
}
class B extends A
{
public override void me()
{ s.o.p(" wat up!");
}
}
class M
{
A a = new B();
a.me();
B b = new A();
b.me();
}
//output :
hi wat up!
Is This Answer Correct ? | 5 Yes | 5 No |
through which algorithm does the garbage collector works? how the garbage collector will understand that the object will going to be deleted?
along with oracle which language will be beneficial to have knowledge with,java,.net,since i m doing oracle have appeared for 8th sem BEIT,plz suggest
What is Partial class and its use?
What are the advantages of Server Controls over HTML/ASP Controls.
In staad pro, how can we design ROOF SLAB?
will it allow to add same value in HashMap class.
what is session state?
what is difference between kpo and it industry? that is in terms of work, package etc
What is the client concept in SAP? What is the meaning of client independent?
What is the merger sort principle and its time complexity.
About CLR, reflection and assemblies?
What is the purpose of <Trigger> element of <updatePanel> in Ajax