[JAVA] 100% faster solution
\n\n# Complexity\n- Time complexity: O(log n)\n Add your time complexity here, e.g. O(n) \n\n- Space complexity: O(1)\n Add your space complexity here, e.g. O(n
\n\n# Complexity\n- Time complexity: O(log n)\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity: O(1)\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\n    public boolean isFascinating(int n) {\n        boolean[] fascinating = new boolean[10];\n        int n2 = 2 * n;\n        int n3 = 3 * n;\n        while(n > 0) {\n            fascinating[n % 10] = true;\n            fascinating[n2 % 10] = true;\n            fascinating[n3 % 10] = true;\n            n /= 10;\n            n2 /= 10;\n            n3 /= 10;\n        }\n        for(int i = 1; i < 10; i ++)\n           if(! fascinating[i]) return false;\n        return true;\n    }\n}\n```\n# PLEASE UPVOTE IF IT WAS HELPFULL
['Array', 'Hash Table', 'Math', 'Java']