如何从现有地图中删除密钥?
if (exists $sampleMap{1})
{
#Here I want to remove the "1" key from sampleMap
}
如何从现有地图中删除密钥?
if (exists $sampleMap{1})
{
#Here I want to remove the "1" key from sampleMap
}
用于delete
删除哈希键:
if (exists $sampleMap{1})
{
delete $sampleMap{1}; #Here I want remove the "1" key from sampleMap.
}
有关更多详细信息,请查看delete。