C # implementation of the above approach
using System ; using System . Collections . Generic ; class GFG { class Point { public int x , y ; public Point ( int first , int second ) { this . x = first ; this . y = second ; } }