|
-
September 28th, 2003, 07:56 PM
#11
"Why are the STL classes not designed to be inherited from"
I find this inheritance useful, why not? (sure not to create its instance by new).
class Matrix : public vector<vector<double> >
{
//provide operator=()
//other operators and operator(int, int) for a[i][j]
//copy constructor
public:
double get_determinant() const;
double get_minor(int row, int col) const;
};
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|