title: Why do we need to assign object of derived class to base class to call a method?
body: <p>I have a base class called Shape and a derived class Rectangle which derives from Shape.</p>
  
  <pre><code>class Shape
  {
      public virtual void Draw()
      { 
          //Draw the Shape
          Console.WriteLine("Draw the Shape");
      }
  }
  class Rectangle : Shape
  {
      public override void Draw()
      {
          Console.WriteLine("Draw Rectangle");
      }
  }
  </code></pre>
  
  <p>I have a very basic doubt that when calling method of my derived class I do something like this.</p>
  
  <pre><code>Shape r1 = new Rectangle();
  r1.Draw();
  </code></pre>
  
  <p>But if I want to invoke method of Rectangle class I can always do like this.</p>
  
  <pre><code>Rectangle r2 = new Rectangle();
  r2.Draw();
  </code></pre>
  
  <p>My question is that why we need to use first method when we can always use the second one which is easy to understand and implement.?</p>