title: How to create global functions in Objective-C
body: <p>I'm developing an iphone app and I need to have some functions to use globally in my classes.</p>
  
  <p>But how can I do this?</p>
  
  <p>I just tried to create <code>functions.h</code> likes this</p>
  
  <pre><code>#include &lt;Foundation/Foundation.h&gt;
  
  - (void)printTest;
  </code></pre>
  
  <p>and in the <code>functions.m</code></p>
  
  <pre><code>#import "functions.h"
  
  - (void)prinTest {
      NSLog(@"test");
  }
  </code></pre>
  
  <p>but it doesn't work. Says me: "Method definition not in a @implementation context".</p>