12-Function - Programming Fundamentals[C Language by SHAH...

Info icon This preview shows pages 1–2. Sign up to view the full content.

Programming Fundamentals [C Language] by: SHAH NAWAZ,UoG,Lahore Calling the C function Topics Covered : Function that return a value, Parameters and use of arguments to pass data to a function, Formal/ Actual parameters, Passing values between functions, Formal/ Actual parameters Function definition A function definition in C programming consists of following parts– syntax return_type function_name( parameter list ); Return Type − A function may return a value. The return_type is the data type of the value the function returns. Some functions perform the desired operations without returning a value. In this case, the return_type is the keyword void . Function Name − This is the actual name of the function. The function name and the parameter list together constitute the function signature. Parameters − parameters are variables defined in the function definition which receive values passed from function call. When a function is called/invoked, you also pass a value or set of values to the parameter. A
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Image of page 2
This is the end of the preview. Sign up to access the rest of the document.
  • Summer '15

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern