#include "point3d.h"
#include<cmath>
Point3D::Point3D(double newX,double newY,double newZ):Point(newX,newY),z(newZ)
{
}
double Point3D::getZ()const
{
return z;
}
double Point3D::getDistance(const Point3D &p) const
{
double D=Point::getDistance(p);
return sqrt(D*D+z*z);
}