Positional parameters được truyền theo thứ tự: void greet(String name, int age) gọi là greet("John", 30).
- Named parameters dùng dấu ngoặc nhọn:
void greet({String? name, int? age})gọi làgreet(name: "John", age: 30). - Named parameters có thể tùy chọn; kết hợp từ khóa
requiredđể bắt buộc chúng.