title: How to clean up the unmanaged resources in C#
body: <p>I Have this class :</p>
  <pre><code>    public class A
      {
  //Some logic code here
      }
  </code></pre>
  <p>My question is <strong>how I can dispose or destroy any object created based on this class after going out the scope?</strong></p>
  <p><strong>For example:</strong></p>
  <pre><code>  A a = new A();
      //some code here
  </code></pre>
  <p>after the <code>//some code here</code> I wanna the <code>a</code> object to destroyed or disposed and releasing his allocated memory.</p>