首页 > 建站教程 > dart >  Dart编程实例 - Set.from()正文

Dart编程实例 - Set.from()

Dart编程实例 - Set.from()

void main() {

   Set numberSet = new Set.from([12,13,14]);

   print("Default implementation :${numberSet.runtimeType}");  

   // all elements are retrieved in the order in which they are inserted

   for(var no in numberSet) {

      print(no);

   }

}