- I see at least one error: distanceFromOrigin -- you should not create a new Point object, for if you do, the distance will always be 0. Use the x and y you have.
- Also, your class has no constructor, and you need at least two, one a default constructor that sets x and y to 0, a constructor that takes 2 ints to allow setting of x and y.
- Also, your x and y variables should be private, and the class should provide getter methods for both, and possibly setter methods, if these are desired.
As for your main method, put whatever you want or are required to put in there. I suspect that you'll want to create a few of your Point objects and test their methods.
As an aside, if this were my code, I'd rename the class to something else so as to not have a name clash with java.awt.Point
.