标签:
class Point{
private:
float x , y;
public:
Point( float a , float b ): x (a) , y (b){}
};
对象数组 作形式参数
float lineFit ( const Point points [] , int nPoint )
主函数中的初始化
int main (){
Point p[6] = { Point ( 1 , 3 ) , Point ( 2 , 4 ) , Point ( 4 , 5 ) , Point ( 6 , 8 ) , Point ( 9 , 12 ) , Point ( 8 , 13 ) }
return 0;
}
标签:
原文地址:http://www.cnblogs.com/greengold/p/5440858.html