Simple C++ Solution Beats 100%
Code\ncpp []\nvector<int> minBitwiseArray(vector<int>& nums) {\n        int n=nums.size();\n        vector<int> ans(n);\n        for(int i=0;i<n;++i){\n        
# Code\n```cpp []\nvector<int> minBitwiseArray(vector<int>& nums) {\n        int n=nums.size();\n        vector<int> ans(n);\n        for(int i=0;i<n;++i){\n            if(nums[i]&1){\n                int j=0;\n                while(nums[i] & (1<<j)){\n                    ++j;\n                }\n                --j;\n                ans[i]=(nums[i] & (~(1<<j)));\n            }\n            else ans[i]=-1;\n        }\n\n        return ans;\n}\n```
['C++']