#include <iostream>
using namespace std;
class Point
{
public:
Point(double x=0,double y=0);
void setPoint(double,double);
double getX( ) const {return x;}
double getY( ) const {return y;}
void show();
protected:
double x,y;
};
Point::Point(double a,double b)
{
x=a;
y=b;
}
void Point::setPoint(double a,double b)
{
x=a;
y=b;
}
void Point::show()
{
cout<<"["<<x<<","<<y<<"]"<<endl;
}
int main( )
{
Point p(2,4);
p.show();
p.setPoint(6,8);
p.show();
return 0;
}