#include <stdio.h>
#include <stdint.h>
uint32_t extract_even_bits(uint32_t reg) {
uint32_t result = 0;
int out_pos = 0;
for (int i = 0; i < 32; i += 2) {
// Extract bit at position i
uint32_t bit = (reg >> i) & 1;
// Place it at the next position in result
result |= (bit << out_pos);
out_pos++;
}
return result;
}
int main() {
uint32_t reg;
scanf("%u", ®);
printf("%u\n", extract_even_bits(reg));
return 0;
}