Challenge 2: Implement the Parametrized Constructor

Can you implement the Derived Class parametrized constructor? A solution is placed in the solution section to help you, but we would suggest that you try to solve it on your own first.

Problem Statement

Implement the constructor, Dell(string name) of the Derived Class Dell which takes a string, name. We have already implemented the Base Class, Laptop, with the Name property and a parameterized constructor.


The laptop’s name is being passed through the parameterized constructor of the Dell class.


Name property is returning Laptop name.

Sample Input

        Dell dell = new Dell("Dell Inspiron");

Sample Output

        dell.Name = "Dell Inspiron"

Get hands-on with 1200+ tech skills courses.