Answer: Following are the key points which fulfill Function Overloading?
1). Number of parameters.
2). Order of parameters.
3). Data-type of parameters.
We can understand this by an example:-
public void display(int id,string name)
{
}
public void display(string name,int id)
{
}
public void display(string name,string value,int id)
{
}
public void display(string id,string name)
{
}
Asked In: Many Interviews |
Alert Moderator