ACartesianPoint - x = inputX; y = inputY; } public int...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
// public double getAngle() { // return Math.atan((double) y/x); // } // public double getRadius() { // return Math.sqrt(x*x + y*y); // } public class ACartesianPoint implements Point { //private int x, y; private int x; private int y; public ACartesianPoint(int inputX, int inputY){
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: x = inputX; y = inputY; } public int getX(){ return x; } public int getY(){ return y; } public double getRadius(){ return Math.sqrt(x*x + y*y); } public double getAngle(){ return Math.atan(((double)y)/x); } }...
View Full Document

This note was uploaded on 10/17/2011 for the course COMP 110 taught by Professor Stotts during the Fall '08 term at UNC.

Ask a homework question - tutors are online