point.txt

来自「用JAVA编写的kmeans算法」· 文本 代码 · 共 52 行

TXT
52
字号
/*
 * Point.java
 *
 * Created on 2007年1月22日, 下午12:50
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package edu.whu.iss.idle.kmeans;

/**
 *
 * @author He Jian
 */
public class Point {
    
    private double x = 0;
    private double y = 0;
    
    /** Creates a new instance of Point */
    public Point(double x,double y) {
        this.setX(x);
        this.setY(y);
    }

    public double getX() {
        return x;
    }

    public void setX(double x) {
        this.x = x;
    }

    public double getY() {
        return y;
    }

    public void setY(double y) {
        this.y = y;
    }
    
    public String toString(){
        return "[" + x + "," + y + "]";
    }
    
    /**
    public static void main(String[] args) {
        System.out.println(new Point(3,4).toString());
    }*/
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?