Confused in inline function

in the notes provided inline function is described as the compiler places a copy of the code of that
function at each point where the function is called at compile time but i am unable to get what that means

Hi @Prakhar2810
C++ provides an inline functions to reduce the function call overhead. Inline function is a function that is expanded in line when it is called. When the inline function is called whole code of the inline function gets inserted or substituted at the point of inline function call. This substitution is performed by the C++ compiler at compile time. Basically if a function is inline, the compiler places a copy of the code of that function at each point where the function is called at compile time.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

hello @Prakhar2810
u have reopened this doubt . what issue u r facing in this ?

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.