#include <iostream>

using namespace std;

class Point {
  public:
    Point(int x = 0, int y = 0) : x(x), y(y) {}
    void show() const;  // overload << 
    int x, y;
};

class Pixel: public Point {
  public:
    Pixel(int x = 0, int y = 0, int color = 0)
//       : color(color)
//       : x(x), y(y), color(color) 
       : Point(x, y), color(color)
    { this->x = 3; }
  private:
    int color;
};


void Point::show() const {
    cout << "(" << this->x << ", " << this->y << ")" << endl;
};


int main() {
    Pixel px(1, 2, 128);

    px.show();

    cout << px.x << endl;

    return 0;
}
