map by reference

Write here if you have problems with your C++ source code

Moderator: Board moderators

Post Reply
Learning poster
Posts: 62
Joined: Mon Jan 24, 2005 6:12 am
Location: Lima,Peru

map by reference

Post by trulo17 » Mon Mar 06, 2006 1:48 am

could anyone tell me how to pass a map to a function by reference?

User avatar
Krzysztof Duleba
Posts: 584
Joined: Thu Jun 19, 2003 3:48 am
Location: Sanok, Poland

Post by Krzysztof Duleba » Mon Mar 06, 2006 2:48 am

Code: Select all

void foo(map<int, int> & mp){
For millions of years, mankind lived just like the animals. Then something happened which unleashed the power of our imagination. We learned to talk and we learned to listen...

Post Reply

Return to “C++”