Compare commits

..

2 commits

Author SHA1 Message Date
eriedaberrie 6edb409e18 2024 day 18 2024-12-17 21:38:52 -08:00
eriedaberrie 1e5b15a387 2024 day 17 2024-12-16 23:48:43 -08:00

View file

@ -6,7 +6,7 @@ vector<int> tape;
// HACK: hardcoded input // HACK: hardcoded input
ll rec(int i, ll a) { ll rec(int i, ll a) {
for (ll aa = a; aa < a + 8; aa++) { for (ll aa = a << 3; aa < (a + 1) << 3; aa++) {
ll b = aa & 7; ll b = aa & 7;
b ^= 1; b ^= 1;
ll c = aa >> b; ll c = aa >> b;
@ -15,7 +15,7 @@ ll rec(int i, ll a) {
if (i == 0) { if (i == 0) {
return aa; return aa;
} else { } else {
ll n = rec(i - 1, aa << 3); ll n = rec(i - 1, aa);
if (n != -1) { if (n != -1) {
return n; return n;
} }