Joanne Neal wrote:
Does that mean that both the key and value need to be the same for an entry to be considered to be in both Maps or is it just the key that is important ?
Edit* Sorry had a brain fart, the keys are days + times, values are appointments. If the day + time is already "busy" then that's it. Basically trying to find "free" days + times.
I'll go have a read about the removeAll method, thanks!
David Ward wrote:So in laymans, Set.removeAll(), takes one Map and removes all keys from it that occur in Map2?
Set.removeAll() takes one Set, not one Map, and removes all elements that occur in the other - be they 'keys', 'widgets', 'fubars', or anything else.
I am NOT certain what happens if you try and remove an element that is not there - I would assume it would be ok, but I didn't really scour the API that closely.