title: C header file format
body: <p>Trying to get a grip on proper format for setting up header files for my external functions that I'm doing for school.</p>
  
  <p>In the .h file I place the <code>#ifndef &lt;token&gt; #define &lt;token&gt;</code> and <code>#endif</code> pre-processor calls around my prototypes but additional <code>#defines</code>, for use within the function itself, go inside the .c file or in the .h?</p>
  
  <p>When adding the whole package to my main program do I just need to add at the top of my main program  <code>#include "name_of_function_pkg.h"</code> or does there need to be a reference to the .c file within the header file too?</p>
  
  <p><strong>[Edit]  Added the code for you as requested.  The whole things works fine but just want to write it by the standard everyone else does.</strong></p>
  
  <p>My main() file:</p>
  
  <pre><code>    #include &lt;stdio.h&gt;
      #include "utils.h"
  
      //  DEFINED Values
  
      #define FALSE 1
      #define TRUE 0
  
      //  MAIN CODE
      int main()
      {
  
      //  Local Variables
          int success = TRUE;
  
          float fValue,fConvert;
          float fSrcFactor,fDstFactor;
  
          char cSourceCurrency;
          char cDestCurrency;
          char cNewline;
  
      //  User Input
          printf("Enter source currency: ");
          scanf("%c%c",&amp;cSourceCurrency,&amp;cNewline);
          printf("Enter destination currency: ");
          scanf("%c%c",&amp;cDestCurrency,&amp;cNewline);
          printf("Enter the value: ");
          scanf("%f",&amp;fValue);
  
          fConvert = convert( cSourceCurrency, cDestCurrency, fValue);
  
  
      //  Output
          if(fConvert == -1)
              {
                  printf("There was an error with the input.");
              }
  
          else printf("%c%.2f = %c%.2f",cSourceCurrency,fValue,cDestCurrency,fConvert) ;
  
  
      //  Exit    
          return 0;
  
      }
  </code></pre>
  
  <p>My utils.h File:</p>
  
  <pre><code>#ifndef UTILS
  #define UTILS 
  
  float convert( char cSourceCurrency, char cDestCurrency, float fValue );
  
  #endif
  </code></pre>
  
  <p>My utils.c File [truncated]</p>
  
  <pre><code>// Should these defines be in the .h file?
  #define CDN 1
  #define YEN 95.04
  #define EUR 0.69
  #define E2Y 137.69
  
  #define FALSE 1
  #define TRUE 0
  
  
  float convert( char cSourceCurrency, char cDestCurrency, float fValue )
  {
  //  Function Variables
  int success = TRUE;
  
  float fConvert; 
  float fSrcFactor,fDstFactor;
  
  
  //  Error Checking
  if( (cSourceCurrency!='Y') &amp;&amp; (cSourceCurrency!='$') &amp;&amp; (cSourceCurrency!='E'))
      {
          success = FALSE;
          return (-1);
      }
  if( (cDestCurrency!='Y') &amp;&amp; (cDestCurrency!='$') &amp;&amp; (cDestCurrency!='E'))
      {
          success = FALSE;
          return (-1);
      }
  </code></pre>