Simple, C++ Solution [beats 98%, 100%]
Runtime: 8 ms, faster than 98.57% of C++ online submissions for Binary Prefix Divisible By 5.\nMemory Usage: 10.6 MB, less than 100.00% of C++ online submission
Runtime: 8 ms, faster than 98.57% of C++ online submissions for Binary Prefix Divisible By 5.\nMemory Usage: 10.6 MB, less than 100.00% of C++ online submissions for Binary Prefix Divisible By 5.\n\n```\n vector<bool> prefixesDivBy5(vector<int>& A) {\n        \n        vector<bool> res;\n        int n = A.size();\n        int num = 0;\n        \n        for(int i=0; i<n; i++)\n        {\n            num = num*2 + A[i];\n            num %= 5;\n            res.push_back(num%5 == 0);\n        }\n        \n        return res;\n    }
['C++']