Dart Programming – Collection Maps

  • Post author:
  • Post category:Dart
  • Post comments:2 Comments
Dart Programming Collection maps

In this guide, we will discuss Collection Maps in Dart programming Language. The Map object is a simple key/value pair. Keys and values in a map may be of any type. A Map is a dynamic collection. In other words, Maps can grow and shrink at runtime. The Map class in the dart:core library provides support for the same.

Example

void main() { 
  var details = new Map(); 
  details['Usrname']='admin'; 
  details['Password']='admin@123'; 
  print(details); 
}     

It should produce the following output −

{Usrname: admin, Password: admin@123} 

Note − The generic implementations of List and Map has been discussed in detailed in the previous chapters.

Next Topic : Click Here

This Post Has 2 Comments

Leave a Reply