• + 0 comments
    long sumXor(long n) {
        long count = 0;
        long binary = n;
        while (binary > 0) {
            count += binary & 1 ? 0 : 1;
            binary >>= 1;
        }
        return 1L << count;
    }
    
    int main() {
        long n;
        scanf("%ld", &n);
    
        printf("%ld\n", sumXor(n));
    		
    		
    #Pratham Gupta
    		
    		
    		
    		
    
        return 0;
    }