title: Objective-C function with default parameters?
body: <blockquote>
    <p><strong>Possible Duplicates:</strong><br>
    <a href="https://stackoverflow.com/questions/561185/optional-arguments-in-objective-c-2-0">Optional arguments in Objective-C 2.0?</a><br>
    <a href="https://stackoverflow.com/questions/871796/objective-c-default-argument-value">Objective-C Default Argument Value</a>  </p>
  </blockquote>
  
  
  
  <p>I'm writing a C function in Objective-C. I want a <em>default value</em> for my last parameter. </p>
  
  <p>I've tried:</p>
  
  <pre><code>foo(int a, int b, int c = 0);
  </code></pre>
  
  <p>but that's C++.</p>
  
  <p>I've also tried:</p>
  
  <pre><code>foo(int a, int b, int c)
  {
      ...
  }
  
  foo(int a, int b)
  {
     foo(a, b, 0);
  }
  </code></pre>
  
  <p>But that's <em>also</em> C++. </p>
  
  <p>Is there a way to do this in Objective-C instead?</p>