Which of the following statements is correct about the C#.NET code snippet given below?adfasdfasd
namespace ConsoleApplication
{
class Sample
{
public int func()
{
return 1;
}
public Single func()
{
return 2.4f ;
}
}
class Program
{
static void Main(string[ ] args)
{
Sample s1 = new Sample();
int i;
i = s1.func();
Single j;
j = s1.func();
}
}
}
Answer: C . Func() cannot be considered overloaded because: return value cannot be used to distinguish between two overloaded functions.