Map | Simple Approach | O(n)
IntuitionMake yours nums array from numbers starting from 1.let's make it :initially nums is empty : nums = {}
for exist x = 1 expressible using numbers of nums
# Intuition
Make yours nums array from numbers starting from 1. 
let's make it :
initially nums is empty : nums = {}
1. for exist x = 1 expressible using numbers of nums, nums must have 1.
2. for x = 2 also because if 1 & 2 are not present in the nums we can't make them expressible using other elements of nums.
3. for x = 3  => if we have 1 & 2 in nums we can make expressible x = 3 using (1 | 2)
4. Similiarly if we see he same pattern like if we have 4 in nums we can make till x=7 number expressible because this is the largest number with 3bits.
5. for x = 8 => it must present in nums because it's the smallest num with 4 bits . If 8 is present we can make x=9 to x=15 usign previous elements. 
<!-- Describe your first thoughts on how to solve this problem. -->

# Approach
Store the count of each number in an unordered_map<int, int> nums_ to check for existence efficiently. Start with x = 1 (smallest power of 2) and repeatedly multiply it by 2. If x is found in nums_, move to the next power of 2. If x is missing, return it as the result.
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity: O(n)
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity: O(n) : The hashmap stores up to n elements.
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```cpp []
class Solution {
public:
    int minImpossibleOR(vector<int>& nums) {
        unordered_map<int,int>nums_;
        for(auto i : nums){
            nums_[i]++;
        }
        int x=1;
        while(1){
           if(nums_[x]){
            x=x*2;
           }
           else{
            return x;
           }
        }
        return -1;
    }
};
```
['Array', 'Bit Manipulation', 'Brainteaser', 'C++']