Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- template<typename T>
- class Point
- {
- public:
- T x;
- T y;
- Point(T x, T y)
- {
- this->x = x;
- this->y = y;
- }
- ~Point()
- {
- }
- };
- class A6 : public Point<int>
- {
- public:
- A6(int x, int y) : Point(x, y) {
- };
- };
- template<typename T>
- class B6 : public Point<T> {
- public:
- B6(T x, T y) : Point(x, y) {
- };
- };
- template<>
- class B6<double> : public Point<double> {
- public:
- B6(double x, double y) : Point(x, y) {
- };
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement