for (var i in a_hashmap[i])
is not correct. It should be
for (var i in a_hashmap)
which means “loop over the properties of a_hashmap, assigning each property name in turn to i“
for (var i in a_hashmap[i])
is not correct. It should be
for (var i in a_hashmap)
which means “loop over the properties of a_hashmap, assigning each property name in turn to i“