#include <stdio.h>
#include <stdint.h>
#define PACK_REG(reg,mode,speed,status) reg = (reg | mode | speed<<3 | 0b00 << 8| status << 10)
uint16_t pack_register(uint8_t mode, uint8_t speed, uint8_t status) {
// Your logic here
uint16_t reg = 0;
return PACK_REG(reg, mode, speed, status);
}
int main() {
uint8_t mode, speed, status;
scanf("%hhu %hhu %hhu", &mode, &speed, &status);
uint16_t reg = pack_register(mode, speed, status);
printf("%u", reg);
return 0;
}