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
What is difference between an Structure and Class?
What are the types of methods in c#?
What is the default value of decimal in c#?
What is the difference between int and int in c#?
What is sqladapter c#?
What is jagged array?
What is dbcontext c#?
What is strong data type in c#?
How long will it take to learn c sharp?
Is enum a class c#?
What is parameter c#?
Show us in simple steps to create setup & deployment project for windows application?
In the page load event I assigned dropdownlist’s datasource property to a valid list. On the submit button click.. The same datasource property is coming as null. Why?
What are satellite assemblies?
What is concrete class in c# with example?