title: Getting a " return type defaults to 'int' " warning when I declare Shortf function before int main(). Why?
body: <pre><code>#include &lt;stdio.h&gt;
  int w=7,v=0;
  shortf(short a, short *b)
  {
      a++;(*b)++;w++;v++;
      printf("13: %d %d %d",a,v,w); return a;
  }
  int main()
  {
      return 0;
  }
  </code></pre>
  
  <p>This is part of my code. It was given to me by a teacher in my University, but when I write it I get 10+ warnings and errors, this is one of them.
  I get a " return type defaults to 'int' " warning for Line 4. Why?
  Note: I am only allowed to use C.</p>