In my the cs106b book we use the expression \"foreach\" to go through a list of words in a Map. I implemented the code and banged my head against the wall facing mysterious erro
Try iterating through the size of the map.
for(int i=0;i
Replace MAP with your map object.
Good luck!
Regards, Dennis M.