Can i make a function with a vector<int> parameter instead of an int array?
mimis 0 Light Poster
Recommended Answers
Jump to Postthe vector class have a copy constructor automatically do what you
worrying about. But the original vector never changes. It creates a new
vector<int> and copy the previous contents to it and after the function
returns that newly created vector will be destroyed.so use this with caution . …
All 4 Replies
Reply to this topic Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.