title: why do you need to include stack.h in stack.c?
body: <p>the implementation level of the array-based</p>
  
  <pre><code>#include "stack.h"
  
  void creat_stack(Stack *s) {
      s-&gt;Top = 0;
  }
  int isFull(Stack s) {
      return (s.Top == Max ? 1 : 0);
  }
  int isEmpty(Stack s) {
      return (s.Top == Max ? 1 : 0);
  }
  void push(stack_entry e, Stack *s) {
      if (!isFull(*s))
          s-&gt;entry[s-&gt;Top++] = e;
      else
          printf("Error : Stack Overflow\n");
  }
  void pop(stack_entry *e,Stack *s) {
      if(!isEmpty(*s))
          *e = s-&gt;entry[s-&gt;Top--];
      else
          printf("Error : Stack Underflow\n");
  }
  </code></pre>
  
  <p>the header file stack.h that consists of the prototypes of the functions along with the definition of the stack element type stack_entry.</p>
  
  <pre><code>#pragma once
  #include &lt;stdio.h&gt;
  
  #define Max 10
  typedef char stack_entry;
  
  typedef struct Stack{
      int Top;
      stack_entry entry[Max];
  }Stack;
  
  void creat_stack(Stack *s);
  int isFull(Stack s);
  int isEmpty(Stack s);
  void push(stack_entry e,Stack *s);
  void pop(stack_entry *e, Stack *s);
  </code></pre>
  
  <p>so my question why i have to include the header file "stack.h" in the "stack.c" file ??</p>