Raj Kumar M
What do u mean by Function Overloading ?
By Raj Kumar M in ASP.NET on Jun 14 2008
  • Bechir Bejaoui
    Jun, 2008 15

    Function overloading means put parameters in the head of the function example: int function() { int a = 3; int b = 2; return a+b; } when I invoke this function in Main method it returns 5 Main() { int x = function(); Write(x); } but if I want that user gives a and b parameters I overload the function I put a and b in the head of the function between the parentheses int function(int a, int b) { retrun a+b; } Main() { int x = function(2,5); write(x); }

    • 0
  • Raj Kumar M
    Jun, 2008 14

    When more than one function is created with the same name, but different is of there arguments . In other words, function names can be overloaded. A function may also have the same name as an attribute. In the casethat there is an ambiguity between a function on a complex type and an attribute of the complex type, the attribute will always be used.

    • 0


Most Popular Job Functions


MOST LIKED QUESTIONS