// 1
}
class Point{
int x,y;
Point(this.x, this.y);
// 命名式构造函数
Point.origin(){
x = 0;... args) {}
class Point {
int x, y;
Point(this.x, this.y);
// 重定向构造函数
// 在函数中调用另一个构造函数的形式...y;
const Point(this.x, this.y); // 构造函数也是常量
}
工厂构造函数
void main(List args) {
Person p =...y, z;
Point(this.x, this.y, this.z);
get point => x + y + z;
// TODO: 这里为啥设置point 却返回z的值?...y;
Vector(this.x, this.y);
Vector operator +(Vector v) => Vector(x + v.x, y + v.y);
Vector operator