Copy 2 first elements of my map

Hello,
I would like to add element 1 and element 2 of my Map choices2 to my Map choices could you tell me how can I do please
Thank you for your help

final Map choices = {};

final Map choices2 = {
‘One’ : ‘1’,
‘TWO’ : ‘2’,
‘TREE’:‘3’,
‘FOR’ :‘4’
}

It is unclear if you want to do dynamically, but in that case the addEntries method of the Map class would let you do that.

final Map choices = {};

final Map choices2 = {
  "one": 1,
  "two": 2,
  "three": 3,
  "four": 4
};

void main() {
  Iterable itChoices = choices2.entries;
  
  List<MapEntry<dynamic, dynamic>> newEntries =
    [itChoices.elementAt(0), itChoices.elementAt(1)];
  
  choices.addEntries(newEntries);

  print(choices);
}

Hth.

P.S. You can find the Map api docs at: https://api.dart.dev/stable/2.8.4/dart-core/Map-class.html

Hello

Thank you for your help