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

15th Apr 2019, 2:40 PM
vicky
3 odpowiedzi
15th Apr 2019, 10:45 PM
vicky