simple and easy C++ solution 😍❤️‍🔥
if it\'s help, please up \u2B06 vote! \u2764\uFE0F\n\n\n# Code\n\nclass Solution {\npublic:\n    int sumOfSquares(vector<int>& nums) \n    {\n        int ans = 
# if it\'s help, please up \u2B06 vote! \u2764\uFE0F\n\n\n# Code\n```\nclass Solution {\npublic:\n    int sumOfSquares(vector<int>& nums) \n    {\n        int ans = 0, n = nums.size();\n        for(int i=1;i<=n;i++)\n            if(n%i==0)\n                ans += (nums[i-1]*nums[i-1]);  \n        return ans;\n    }\n};\n```
['Array', 'Enumeration', 'C++']