Easy cpp solution using set
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\nWe simply write a function, seperating the username and domain name using
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\nWe simply write a function, seperating the username and domain name using the positon of @ in the string and return a new string. Then push that new string into a set to make values unique. \n\n\n\n# Code\n```\nclass Solution {\npublic:\nstring uniqueEmails(string &s){\n\n    int pos = s.find(\'@\');\n\n    string userName = s.substr(0 , pos);\n    string domain = s.substr(pos);\n\n    string localName;\n\n    for(auto &ch : userName){\n\n        if(ch==\'+\'){\n            break;\n        }\n        if(ch != \'.\'){\n            localName.push_back(ch);\n        }\n    }\n    return localName + domain;\n}\n    int numUniqueEmails(vector<string>& emails) {\n        set<string> st;\n\n        for(string &s : emails){\n            string standardEmail = uniqueEmails(s);\n            st.insert(standardEmail);\n\n        }\n\n        return st.size();\n        \n    }\n};\n```
['Ordered Set', 'C++']