Flutter是什么
Flutter是谷歌的移动UI框架,可以快速在iOS和Android上构建高质量的原生用户界面。 Flutter可以与现有的代码一起工作。...print(e);
}
try {
1 ~/ 0;
} on IntegerDivisionByZeroException { // 捕获指定类型的异常
print("error..."); // 打印出error
} finally {
print("over"); // 打印出over
}
类(Class)
不需要用private, protected, public...this.gender);
sayHello() {
print("hello, this is $name, I am $age years old, I am a $gender");
}
}
getter...width, height几个参数
Rectangle(this.left, this.top, this.width, this.height);
// right, bottom两个成员变量提供getter