📜  飞镖代码示例中列表中的 foreach 循环

📅  最后修改于: 2022-03-11 14:48:07.349000             🧑  作者: Mango

代码示例1
main() {
    List list = new List();
    list.add('one');
    list.add('two');
    list.add('twelve');
    list.forEach((element) => print(element));

    Set set = Set.from(list);
    set.forEach((element) => print(element));    
}