Sir, I had a doubt.
If for example we take an unordered map as
unordered_map <int,int>m
and then we do something like m[d]++ .
Here if we will check m.find(d)!=m.end() then it will come.
now if we subtract 1 and now we have m[d]=0 right. So, if we will check for m.find(d) will it be equal to m.end() or it is still present but its value is 0???
Doubt in a concept;
hello @vageesha
find will check whether the key (d) is present or not , it has nothing to do with the value correponding to that key
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.