C Programming

Function Declaration

Posted on 17th February 2014

Like variables, a function has to be declared before it can be used in the program. A function declaration has the following syntax

returnType functionName(arg_1_type, arg_2_type, .... arg_N_type);

Function Declaration Example

int sum(int, int);

This declares a function named sum which takes two integer type arguments and returns a integer value.

Post a comment


Nothing yet..be the first to share wisdom.