[C++] Simplest Solution using frequency.
Complexity\n- Time complexity:\nO(1)\n\n- Space complexity:\nO(1)\n\n# Code\n\nclass Solution {\npublic:\n    bool isFascinating(int n) {\n\n        if(n >= 334
# Complexity\n- Time complexity:\nO(1)\n\n- Space complexity:\nO(1)\n\n# Code\n```\nclass Solution {\npublic:\n    bool isFascinating(int n) {\n\n        if(n >= 334) return false;\n\n        vector<int> freq(10, 0);\n\n        string temp = to_string(n);\n        n = 2 * n;\n        temp += to_string(n);\n        n = n/2 * 3;\n        temp += to_string(n);\n\n        cout << temp << endl;\n\n        for(int i=0; i<temp.size(); i++) {\n            freq[temp[i] - \'0\']++;\n            if(temp[i] == \'0\' || freq[temp[i] - \'0\'] > 1) return false;\n        }\n\n        return true;\n        \n    }\n};\n```
['Hash Table', 'Math', 'C++']