KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I tried to pass const with vector it works: Ex: void damn(const vector <bool> &bb) { for (int i = 0; i < bb.size(); i++) cout << bb[i] << endl; } But when trying with map, it does not: void pas(const map <string, float> &mm) { cout << mm["a"]; cout << mm["b"]; } I wonder why it doesn't.
Tags (comma-separated)
Save Edits
Cancel