Fixed length List
Dart, Flutter 2021. 1. 28. 13:07
728x90
void main() {
//List<String> str = [];
List<String> str = new List(3);
str[0] = "aaa";
str[1] = "b";
List<String> str2 = new List.from(['aaa', 'b']);
}
반응형
'Dart, Flutter' 카테고리의 다른 글
캐스케이드(Cascade Notation) (0) | 2022.01.11 |
---|---|
얕은 복사(shallow copy), 깊은 복사(deep copy) (0) | 2022.01.11 |
ListView (0) | 2021.12.30 |
Error: The argument type 'String' can't be assigned to the parameter type 'Uri'. (0) | 2021.12.30 |
Function(optional parameters, named parameters) (0) | 2021.01.29 |
Fixed length List (0) | 2021.01.28 |