You are viewing a single comment's thread. Return to all comments →
vector reverseArray(vector a) {
//solution approach 1 reverse(a.begin(),a.end()); return a; //solution appraoch 2 // int n=size(a); // vector<int> ans; // for(int i=n-1;i>=0;i--) // { // ans.push_back(a[i]); // } // return ans;
}
Seems like cookies are disabled on this browser, please enable them to open this website
Arrays - DS
You are viewing a single comment's thread. Return to all comments →
vector reverseArray(vector a) {
}