Any file must have its data organised in a certain order. This will typically be:
Within each of these sections, the order of items is important, since any object must be defined before it can be used. In particular, functions which return values must be defined in the file before they are called. This definition might be one of the following:
float find_max(a, b, c)
float a, b, c;
{ /* etc ... ... */
would have a dummy declaration of
float find_max();The dummy declaration may occur among the global variables, or be local to each function where it is called. Dummy declarations can also be made in header files, which are read in using #include.
It is most important to remember that all C objects should be declared before they are used.