[c++] fast and easy solution using two pointer algorithm
Two pointer approch \nplease upvote my solution if you like it\n\'\'\'\nclass Solution {\npublic:\n\n    vector sortArrayByParity(vector& A) {\n        int j=0;
**Two pointer approch **\nplease upvote my solution if you like it\n\'\'\'\nclass Solution {\npublic:\n\n    vector<int> sortArrayByParity(vector<int>& A) {\n        int j=0;\n        for(int i=0;i<A.size();i++)\n\t\t{\n            if(A[i]%2==0)\n\t\t\t{\n                swap(A[i],A[j]);\n                j++;\n\t\t\t}\n\t\t}\n        return A;\n    }\n};\n\'\'\'
['Two Pointers', 'C', 'C++']