#include <iostream>
using namespace std;


int suma_bits_potencies_parells(int n);


int main() {
    int x;
    while (cin >> x) cout << suma_bits_potencies_parells(x) << endl;
}

