title: C# Syntax lambdas with curly braces
body: <pre><code>delegate int AddDelegate(int a, int b);
  AddDelegate ad = (a,b) =&gt; a+b;
  
  
  AddDelegate ad = (a, b) =&gt; { return a + b; };
  </code></pre>
  
  <p>The two above versions of AddDelegate are equivalent.  Syntactically, why is it necessary
  to have a semicolon before and after the <code>}</code> in the second AddDelegate? You can a compiler error <code>; expected</code> if either one is missing.</p>