C++ | easy to understood
\tint minDeletion(vector& nums) {\n\t\t\tint size = nums.size();\n\t\t\tint cnt = 0;\n\t\t\tfor(int i=0;i< size-1;)\n\t\t\t{\n\t\t\t\tif(nums[i] == nums[i+1])\n
\tint minDeletion(vector<int>& nums) {\n\t\t\tint size = nums.size();\n\t\t\tint cnt = 0;\n\t\t\tfor(int i=0;i< size-1;)\n\t\t\t{\n\t\t\t\tif(nums[i] == nums[i+1])\n\t\t\t\t{\n\t\t\t\t\ti++;\n\t\t\t\t\tcnt++;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\ti += 2;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(size % 2 == 0  and cnt % 2 != 0)\n\t\t\t{\n\t\t\t\tcnt++;\n\t\t\t}\n\t\t\tif(size % 2 == 1 and cnt % 2 == 0)\n\t\t\t{\n\t\t\t\tcnt++;\n\t\t\t}\n\t\t\treturn cnt;\n\t\t}
['C']