C - Function Declaration

From EdWiki

Revision as of 09:30, 23 June 2015 by Jshankar (Talk | contribs) (1 revision imported: EdWiki -- Emsys pages from Shukra)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Function Declaration

return_type function_name(arg_type arg_name, …);


return_type is the type of data that the function returns. If the function doesn’t return any data, then a data type of void should be specified.
function_name is the name of the function itself.
arg_type is the data type that function accepts. If the function doesn’t take any parameters, a data type of void should be specified.
arg_name is the variable name of the argument.