📅  最后修改于: 2022-03-11 15:04:17.054000             🧑  作者: Mango
var myMap = {};
myMap[newKey] = newValue;
// ...
// Another method
var myMap = new Map()
myMap.set("key0","value")
// ...
myMap.has("key1"); // evaluates to false, assuming key1 wasn't set