0
Vector to map?
Hello, I try to make a map from a vector but I donât know how to do it good. I have a vector of strings and the map had to have the strings of the vector and it had to count the strings and to give it a key. F.e. Vector<string> words={ âhelloâ, âhowâ , âareâ, âhelloâ} Output hello: 2 how: 1 are: 1 I tried something. https://code.sololearn.com/cLy2XJQr8Hzx/?ref=app
3 Answers
0
~ swim ~ do you mean like this?
https://code.sololearn.com/cLy2XJQr8Hzx/?ref=app