Answer Posted / rakesh
A class contains more than one function with the same name
but different method signature ie different access
type,return type,parameters.
public void int sum(int i,int j)
{
int tot=i+j;
Console.WriteLine(tot);
}
public void double sum(double p,double q)
{
double tot=p+q;
Console.WriteLine(tot);
}
if we are passing integer values means the first function
will invoke,and if we are passing double values means the
second will work.This is method overloading.
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
How do I automate my desktop application?
Is 0 an unsigned integer?
What is a trace and asset? Explain some differences?
What is xml serialization and deserialization in c#?
What is the difference between proc. Sent by val and by sub?
Why are strings immutable c#?
Does c# support const methods, properties, or events?
What are the boolean data types in c#?
what is partial assembly reference
What is private class in c#?
What is method in c#?
What are the 4 pillars of any object oriented programming language?
Define assert() method? How does it work?
What to implement on my class Finalize or IDisposable
What is session state in asp net c# with example?