C++(2-line) | map| very easy solution
Please upvote if you find my solution helpful!!\n\nclass Solution {\npublic:\n    vector<int> findLonely(vector<int>& nums) {\n        vector<int> ans;\n       
Please upvote if you find my solution helpful!!\n```\nclass Solution {\npublic:\n    vector<int> findLonely(vector<int>& nums) {\n        vector<int> ans;\n         unordered_map<int,int> mp;\n        int n = nums.size();\n        for(int i=0;i<n;i++){\n            mp[nums[i]]++;   //storing frequency of elements\n        }\n        \n         for(int i=0;i<n;i++){\n\t\t //simply checking the given condition in question \n           if(mp[nums[i]]==1 && mp[nums[i]-1]==0 && mp[nums[i]+1]==0 ){\n              ans.push_back(nums[i]);\n           }\n        }\n       \n        return ans;\n    }\n};\n```
['C', 'C++']