Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

write the Syntax for Function or Method Overriding?

Answer Posted / pritam kumar

class parent
{
public virtual void print()
{
Console.Writeline ("method from parent class");
}
}
class child:parent
{
public override void print()
{
Console.Writeline("method from base class ");
}
}

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is ulong in c#?

983


What is lastindexof c#?

810


Which is faster array or arraylist in c#?

849


What does question mark mean in c#?

933


What do u meant by "SBI" of an object?

924


How do I use the 'using' keyword with multiple objects?

897


Explain synchronous and asynchronous operations?

928


Explain the difference between boxing and unboxing.

964


What is Global Assembly Cache (GAC) and what is the purpose of it? (How to make an assembly to public? Steps) How more than one version of an assembly can keep in same place?

983


Give an example of removing an element from the queue?

886


What is a datacontract?

861


How string definitions will prevent escaping on backslashes in C#?

933


Why do we use abstraction in c#?

849


What is an indexer in c#?

925


Can we override interface methods in c#?

804