python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
Creating a std::vector of derived classes
Assume that I have an Abstract Class
class AbstractClass {
public:
virtual int get() const = 0;
};
and two different Derived classes
class DerivedClassA : public AbstractClass {
public:
int g...
Carmelo Evoli
Votes: 0
Answers: 2
Python multiple inheritance confusion
I've been trying to understand how to make sure all super().__init__()s run when writing a class that inherits from two unrelated classes. Based on answers such as this and others like it, calling sup...
lte__
Votes: 0
Answers: 1
Is it good practice to declare derivate classes in the same C++ header?
I'm declaring a pure virtual class that will provide a unified interface for a handful of derived classes. My instinctual way to organize this would be to create a base folder with the header for the ...
none none
Votes: 0
Answers: 2
can derived class access base class non-static members without object of the base class
can derived class access base class non-static members without object of the base class
class base
{
public:
int data;
void f1()
{
}
};
class derived : base
{
public :
void ...
Mathews lee
Votes: 0
Answers: 1