C++ | Simple Solution | O(N) | HashMap
class Solution {\npublic:\n    vector findLonely(vector& nums) {\n        \n        unordered_map m;\n        for(auto &i : nums)\n            m[i]++;\n        
class Solution {\npublic:\n    vector<int> findLonely(vector<int>& nums) {\n        \n        unordered_map<int, int> m;\n        for(auto &i : nums)\n            m[i]++;\n        \n        nums.clear();\n        for(auto &i : m)\n            if(i.second == 1 && m.find(i.first + 1) == m.end() && m.find(i.first - 1) == m.end())\n                nums.push_back(i.first);\n        \n        return nums;\n    }\n};
['C']