Point class code is as following: Java Code: public class Point { public int x = 0; public int y = 0; //constructor public Point(int a, int b) { x = a; y = b; } } Single constructor is present in this class. One may do the recognition of the constructor as same name is used by the declaration as the class does & no return type is there. Constructor present will be taking 2 integer ...
public class Point { public int x = 0; public int y = 0; //constructor public Point(int a, int b) { x = a; y = b; } }
thanks...
sorry for all the questions
thanks...
06-14-2013, 02:22 PM in gbonecapone