answersLogoWhite

0


Best Answer

Function calling is when you call a function yourself in a program. While function invoking is when it gets called automatically.

For example, consider this program

struct s

{

int a,b,s;

s()

{

a=2;

b=3;

}

void sum()

{

s=a+b;

}

};

void main()

{

struct s obj; //line 1

obj.sum(); // line 2

}

Here, when line 1 is executed, the function(constructor, i.e. s) is invoked.

When line 2 is executed, the function sum is called.

User Avatar

Wiki User

βˆ™ 13y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

βˆ™ 12y ago

The same as the difference between the person making a telephone call and the person receiving that call. The function that makes a function call is the calling function. The function it calls is the called function. The called function may call other functions, thus making it the calling function for the functions it calls.

This answer is:
User Avatar

User Avatar

Wiki User

βˆ™ 15y ago

These are situation-dependent names. When one function is calling another, it is known as the calling function. The function that it calls is known as the called function.

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the difference between the calling function and called function?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

What is the difference between passing an array and passing single value data to a function?

Passing a single value to a function is often just a simple integer. But passing an array, character string or other data structure is typically "pass by reference", or in other words, the calling statement will 'point to' the place in memory where the data structure resides.When a function is called using a pointer to a data structure, both the calling environment and the called function are referencing the same data; any changes made to the data in the structure by the function will have changed the data that the original calling environment sees.However, when a value is passed to a function, the function creates it's own copy of the value, and can change it in any way without changing the original value.


Why we use function prototyping in c language?

You could just define the whole function before it is called, like this:void do_nothing(){}main(){do_nothing();}but if you define the function after it is called, the compiler will arrive at the function's calling before its actual definition. If you prototype your function earlier in the code than the function's call, the compiler will look for the function first.Hope I was able to help.


What are the different types of function in c plus plus programming?

There are five types of functions and they are:Functions with no arguments and no return values.Functions with arguments and no return values.Functions with arguments and return values.Functions that return multiple values.Functions with no arguments and return values.Functions with no arguments and no return value.A C function without any arguments means you cannot pass data (values like int, char etc) to the called function. Similarly, function with no return type does not pass back data to the calling function. It is one of the simplest types of function in C. This type of function which does not return any value cannot be used in an expression it can be used only as independent statement.Functions with arguments and no return value.A C function with arguments can perform much better than previous function type. This type of function can accept data from calling function. In other words, you send data to the called function from calling function but you cannot send result data back to the calling function. Rather, it displays the result on the terminal. But we can control the output of function by providing various values as arguments. Functions with arguments and return value.This type of function can send arguments (data) from the calling function to the called function and wait for the result to be returned back from the called function back to the calling function. And this type of function is mostly used in programming world because it can do two way communications; it can accept data as arguments as well as can send back data as return value. The data returned by the function can be used later in our program for further calculations. Functions with no arguments but returns value.We may need a function which does not take any argument but only returns values to the calling function then this type of function is useful. The best example of this type of function is "getchar()" library function which is declared in the header file "stdio.h". We can declare a similar library function of own. Functions that return multiple values.So far, we have learned and seen that in a function, return statement was able to return only single value. That is because; a return statement can return only one value. But if we want to send back more than one value then how we could do this? We have used arguments to send values to the called function, in the same way we can also use arguments to send back information to the calling function. The arguments that are used to send back data are called Output Parameters.It is a bit difficult for novice because this type of function uses pointer


When a function does not return a value what kind of function is it called?

In most computer languages, a procedure that returns a value is called a function and a procedure that does not return a value is called a subroutine or subprogram. Usually the languages treat the passing of arguments/parameters differently between functions and subroutines. The C language does not distinguish between them. A subroutine that does not return a value is define as a "void" function indicating that no return value is used or available.


What is the potential difference between 2 points in a circuit called?

Voltage drop

Related questions

Difference between function and objective function?

The linear function Z=c1x1+c2x2+c3x3+..........+cnxn which is to minimized or maximized is called Objective Function of general Linear Programming Problem.The innequalities of LPP are called constraints.


What actually happens when function get called how the compiler is reading the next instruction after completing that function?

When a function gets called, the processor first stores the address of the calling function in a structure called activisation structure and jumps to the called function. Then it allocates the memory for the local variables and initializes them. Then it does the processing in that function. After that it deallocates the memory allocated for the local variables and returns to the calling function. When a function gets called, the processor first stores the address of the calling function in a structure called activisation structure and jumps to the called function. Then it allocates the memory for the local variables and initializes them. Then it does the processing in that function. After that it deallocates the memory allocated for the local variables and returns to the calling function.


Who is calling main function in c?

in c main function initailly called by operating system.


What is the difference between passing an array and passing single value data to a function?

Passing a single value to a function is often just a simple integer. But passing an array, character string or other data structure is typically "pass by reference", or in other words, the calling statement will 'point to' the place in memory where the data structure resides.When a function is called using a pointer to a data structure, both the calling environment and the called function are referencing the same data; any changes made to the data in the structure by the function will have changed the data that the original calling environment sees.However, when a value is passed to a function, the function creates it's own copy of the value, and can change it in any way without changing the original value.


A rigid bar that pivots about a fixed point?

function calling stands for the function consists of semicolean but the called function is refers to the body of the function.


What is the difference between multichannel and multidimensional signals?

if a signal is a function of single independent variable,then signal is called multichannel signal. if a signal is function of multiple independent variable then signal is called multidimensional signal.


3 What is the difference between a function procedure and a subroutine procedure?

Both a function and a subroutine are examples of out-of-line execution calls to code. The main difference is that a function call can be part of an expression and returns a value, whereas the subroutine can be called standalone and does not return a value.


What is the difference between succeeding terms called?

The difference between succeeding terms in a sequence is called the common difference in an arithmetic sequence, and the common ratio in a geometric sequence.


Why we use function prototyping in c language?

You could just define the whole function before it is called, like this:void do_nothing(){}main(){do_nothing();}but if you define the function after it is called, the compiler will arrive at the function's calling before its actual definition. If you prototype your function earlier in the code than the function's call, the compiler will look for the function first.Hope I was able to help.


The difference between actual and standard cost caused by the difference between the actual quantity and the standard quantity is called the?

The difference between actual quantity and standard quantity is called the material quantity variance.


What is the relationship between an input and output called?

A function.


What is the difference between the greatest and least numbers in the set of data is called?

The difference between the greatest and least numbers in a set of data is called the range.