title: Destructor with copy constructor
body: <p>I want to use destructor in CPP, but, compiler is giving warning &quot;undefined reference&quot;.</p>
  <pre><code>class trial{
  private:
      int number;
  public:
      trial(){};
      trial(int num) {
          number=num;
      };
      ~trial();
  };
  </code></pre>
  <p>Trial class constructor gets value from main function. Help me by telling me whats incorrect in constructor. Thanks in advance :)</p>