i have 2 functions, int add(int a,int b);
double add(int a,int b); does this code implement
overloading? if not what will be the error?

Answer Posted / dhakir hussain

it will throw an error because the function overloading is
acheived by
1) changing the number of parameters
2) changing the order of parameters of different datatypes

we can't acheive function overloading by changing the
return type

Is This Answer Correct ?    26 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is garbage collection in .net? Explain the garbage collection process?

568


Explain asp.net?

614


What is the benefit of .net core?

504


Do you know what is lambda expressions in c#?

552


Explain what are possible implementations of distributed applications in .net?

538






What is Event - Delegate? clear syntax for writing a event delegate

1556


What are pdbs?

590


Please explain when should you use .net web forms over asp.net mvc?

552


What is managed code and managed data in .net?

595


What is value type and refernce type in .net?

591


Tell us the difference between managed and unmanaged code?

527


I'm having some trouble with cas. How can I troubleshoot the problem?

577


What makes .net core cross platform?

524


Tell us the differences between an interface and an abstract class in .net?

562


Please explain what is a delegate?

693