title: Declaring an object of a subclass when the base class is abstract
body: <p>I am learning about virtual functions and abstract classes and it seems that I have a difficulty in comprehending something. Let's say I have this code:</p>
  
  <pre><code>class animal {
    public:
      virtual void show()=0;
  };
  
  class dog : public animal {
    int weight;
  };
  
  
  int main()
  {
    //animal a;
    dog d;
    return 0;
  };
  </code></pre>
  
  <p>I understand how animal a is incorrect because the animal class is abstract and I am not allowed to declare objects of this class. However, why the dog d is also incorrect? (given that the class dog is not abstract and so I can declare dog objects)</p>
  
  <p>Thanks in advance!!</p>