[erlang-questions] Updating a map
Oliver Korpilla
Oliver.Korpilla@REDACTED
Wed Jan 30 13:47:21 CET 2019
Hello, Donald.
You could use lists:foldr/3 to insert a list of key values into a map.
You would use the map itself as a the accumulator.
Best regards,
Oliver
Gesendet: Mittwoch, 30. Januar 2019 um 13:27 Uhr
Von: "Donald Steven" <t6sn7gt@REDACTED>
An: "Erlang Questions" <erlang-questions@REDACTED>
Betreff: [erlang-questions] Updating a map
The documentation for maps:update states: update(Key, Value, Map1) ->
Map2, but since update has an arity of 3, this doesn't work:
update(Key1, Value1, Key2, Value2, Map1) -> Map2. Is there an
other-than one-by-one-sequential-update to update more than one
key-value in one shot?
Thanks.
Don
_______________________________________________
erlang-questions mailing list
erlang-questions@REDACTED
http://erlang.org/mailman/listinfo/erlang-questions
More information about the erlang-questions
mailing list