Easy Concise | Using Find & Erase | C++
Let\'s start the cleaning process\n\nFeel free to ask anything, these are some basic functions.\nPreety much it got everything that you already are thinking.\n\
**Let\'s start the cleaning process**\n\nFeel free to ask anything, these are some basic functions.\nPreety much it got everything that you already are thinking.\n\n```\nclass Solution {\npublic:\n    int numUniqueEmails(vector<string>& emails) {\n            \n        for(auto &x:emails){\n            auto pos2 = x.find(\'@\');\n            if(pos2 < x.size())\n                x.erase(remove(x.begin(),x.begin()+pos2,\'.\'),x.begin()+pos2);\n            \n            auto pos1 = x.find(\'+\');\n            pos2 = x.find(\'@\');\n            if(pos1 < x.size() and pos2 < x.size())\n                x.erase(pos1,pos2-pos1);\n        }\n        \n        unordered_set<string> ans(emails.begin(),emails.end());\n        return ans.size();\n    }\n};\n```
['C']