title: Multiple definition of main()
body: <p>Hi guys trying to use two main() and getting this error multiple definition of main(). I renamed my main functions then why is this error and also first defined here for my print().
  header file:</p>
  
  <pre><code>#ifndef TOP_H_
  #define TOP_H_
  
  #include &lt;stdio.h&gt;
  #include &lt;string.h&gt;
  #define onemain main
  #define twomain main
  inline void print();
  
  
  #endif /* TOP_H_ */
  </code></pre>
  
  <p>c file one:</p>
  
  <pre><code>#include "top.h"
  void print();
  int onemain()
  {
      print();
      return 0;
  }
  void print()
  {
  printf("hello one");
  }
  </code></pre>
  
  <p>c file two:</p>
  
  <pre><code>#include "top.h"
  void print();
  int twomain()
  {
      print();
      return 0;
  }
  void print()
  {
  printf("hello two");
  }
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/kKSQu.png" alt="Error snapshot"></p>