| 12 | using namespace std; |
| 13 | |
| 14 | class Solution { |
| 15 | public: |
| 16 | bool containsDuplicate(vector<int>& nums) { |
| 17 | unordered_map<int, int > map; |
| 18 | for (int i : nums) { |
| 19 | if (map.find(i) == map.end()) { |
| 20 | map[i] = 1; |
| 21 | } else { |
| 22 | return true; |
| 23 | } |
| 24 | } |
| 25 | return false; |
| 26 | } |
| 27 | }; |
| 28 | |
| 29 | int main() { |
| 30 | Solution a; |
nothing calls this directly
no outgoing calls
no test coverage detected