Vector to map? | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
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
1 Resposta
15th Apr 2019, 10:45 PM
vicky