I googled this topic but everything I came across wasn't what I wanted. I am trying out the example posted in classes I tutorial but using constructors. My first guess was constructors will be inherited. Upon some google research, I found out that they aren't but can be manually inherited. My question is, how can I use variable rect (class rectangle) and tri(class triangle) to assign values for length and width (width is also assumed as height for triangle) using the constructor dimensions(){}?
When derived objects are created the base constructor is called first automatically. So if you just created an object of triangle/rectangle in this example the dimensions constructor will get called and let you assign the values.
Not 100% sure if this is what you are asking for though.