1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
| const struct __attribute__((aligned(32))) tree_node { int val; const struct tree_node *ls, *rs; } t[15] = { {0x024, &t[1], &t[2]}, {0x008, &t[5], &t[3]}, {0x032, &t[4], &t[6]}, {0x016, &t[12], &t[10]}, {0x02d, &t[7], &t[13]}, {0x006, &t[8], &t[11]}, {0x06b, &t[9], &t[14]}, {0x028, NULL, NULL}, {0x001, NULL, NULL}, {0x063, NULL, NULL}, {0x023, NULL, NULL}, {0x007, NULL, NULL}, {0x014, NULL, NULL}, {0x02f, NULL, NULL}, {0x3e9, NULL, NULL} };
int fun7(struct tree_node *x, int y) { if (x == NULL) { return -1; } else { if (x->val <= y) { if (x->val == y) { return 0; } else { return 2 * fun7(x->rs, y) + 1; } } else { return 2 * fun7(x->ls, y); } } }
void secret_phase() { long x = strtol(read_line(), NULL, 10);
if (x > 1001 || x < 1) { explode_bomb(); }
if (fun7(t, x) != 2) { explode_bomb(); } ... }
|