C++ Simple Soln. || 4 lines
\n  //aX + bY = k has __integer solution__ (X, Y) if k is multiple of gcd(a, b)\n    //here k=1 so __gcd should be 1\n    //Subset has gcd 1 == whole array shou
```\n  //aX + bY = k has __integer solution__ (X, Y) if k is multiple of gcd(a, b)\n    //here k=1 so __gcd should be 1\n    //Subset has gcd 1 == whole array should have 1\n    bool isGoodArray(vector<int>& nums) {\n        int k=nums[0];\n        for(auto i:nums){\n            k=__gcd(k,i);\n        }\n        return k==1;\n    }\n```
[]