Skip to content

Commit

Permalink
day24
Browse files Browse the repository at this point in the history
  • Loading branch information
vslinko committed Dec 25, 2024
1 parent 68bc95c commit d4dec2f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/day24.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const INPUT_GATES_POS: usize = (X_Y_SIZE + X_Y_SIZE) * INITIAL_VALUE_LINE_LENGTH
const CONTEXT_SIZE: usize = GATES_COUNT + X_Y_SIZE * 2;
const EDGES_COUNT: usize = 266;
const STACK_SIZE: usize = 90;
const WIRES_TO_SWAP: usize = 8;
const X: usize = b'x' as usize;
const Y: usize = b'y' as usize;
const Z: usize = b'z' as usize;
Expand Down Expand Up @@ -251,7 +252,7 @@ unsafe fn inner2(input: &str) -> String {
context.insert(to, Gate::new(a, op, b));
});

let mut swaps = Vec::with_capacity(8);
let mut swaps = Vec::with_capacity(WIRES_TO_SWAP);
let mut prev_output = gate_output(&context, key2(X, 0), OP_AND, key2(Y, 0));

(1..Z_SIZE - 1).for_each(|i| {
Expand Down

0 comments on commit d4dec2f

Please sign in to comment.