static void Main(string[] args) { Console.WriteLine("Cwiczenie2"); // (a) Point2D_private point_private1; //Console.WriteLine(point_private1.ToString()); //Nie da się // (b) Point2D_private point_private2 = new Point2D_private(); Console.WriteLine(point_private2.ToString()); // (d) Point2D_konstruktor point_konstruktor1 = new Point2D_konstruktor(); point_konstruktor1.Print2DPoint(); }
public double Dist(Point2D_private point) { return(Math.Sqrt((x - point.x) * (x - point.x) + (y - point.y) * (y - point.y))); }