From 77fba87ef6a0feb04a9a3e1d10c55ceb99070edd Mon Sep 17 00:00:00 2001 From: Keenan Tims Date: Tue, 24 Dec 2024 21:34:47 -0800 Subject: [PATCH] day25: complete solution sill need to finish day 21 for the last star! --- .aoc_tiles/tiles/2024/24.png | Bin 7129 -> 8503 bytes .aoc_tiles/tiles/2024/25.png | Bin 4105 -> 7310 bytes README.md | 5 +- src/day25.rs | 143 +++++++++++++++++++++++++++++++++++ src/lib.rs | 1 + 5 files changed, 148 insertions(+), 1 deletion(-) create mode 100644 src/day25.rs diff --git a/.aoc_tiles/tiles/2024/24.png b/.aoc_tiles/tiles/2024/24.png index 89f755a53ddf7fbcc7c5dac0dfaa98d43cefac9d..b966019b6923a06dbb2c5011aec805b8c07388e8 100644 GIT binary patch literal 8503 zcmXAvbyO5@7srQENSxQ2XP6-i~E`dc_L29X`5tf#amXz)g zge9cw-QRi7xf6fPnR%X>``r7v-#by-uT>rp(-Q*#@IXx!tcyMNVK*B>Tw8FZF%1_5uxE8C5du5Px>|9TT1%EItflCGy8`L@QJBI!MT@sx}+PDOXj2s;)dA z28hzS3CjfdJoI@;+mPRqo*mVaY-gi_$W#3lfH&Gc8WMJ&-oEzCYyq+W@ggUnBA#qr zVGYt+m@zt;%)Rh3u${`iBYzO|Pm9Hn0zc`vN-|z<&8!1`kcYbcZG559mzj@3l+=y* z(#C>lVS*M;xraiJh4}=AmX6bWb>dKAw)Po>+OjIH=d7@xezAYm^`~^0(8E059UOq= z@yk?W{gUn&C*I1yf1TVchN}gZdjft8OE)L^a@Wy!$Z{va#gmL}3N9MkVv#>yU^B$> z=tuj}N5RHX#+6G4q3AD^!1AtxhfkK)P$o4(Rfe0EW}w=WR6!efX^K-Q0ckyt`B1r( zaIdAtW{7y8G!>?gn@>q)_%YAXd7La5!{pOTfPeu&^|iZ(^^X|Gb)`v<;Q`p6S`S@V zc)8+~dM-ftiPnIwp*2?34FK4>)lbo~o=0ccyD<(_r5545+_}^&R!i{nHcXUAHV$M{Z`$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7mg?FE0C*UE5Gnp11Sg?)u|{K5gA@Q?giU z^B)`!;B0y|4^!qQP&+zlO95!Q*ZI&H?TEAwb#bXt-g2C%Fe5m2Y zy$1{Mj}z;~x>!xC6id77kX@|S|K0o*D@1V)v53dojtBUOk0u6N3_f#-5u*P0Yyx<8 z2@m5(J6NRp%+9C@^_tf;*GjdzwwjN;wrDmG#N2jQD3g#Z8m diff --git a/README.md b/README.md index bd4c125..dfc7c92 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@

- 2024 - 46 ⭐ - Rust + 2024 - 48 ⭐ - Rust

@@ -74,4 +74,7 @@ + + + diff --git a/src/day25.rs b/src/day25.rs new file mode 100644 index 0000000..2b8d7b4 --- /dev/null +++ b/src/day25.rs @@ -0,0 +1,143 @@ +use aoc_runner_derive::aoc; +use itertools::Itertools; + +enum LockKey { + Lock, + Key, +} + +#[derive(Clone, Debug)] +struct LockPile { + keys: Vec>, + locks: Vec>, +} + +fn parse_grid(lines: &Vec<&str>) -> (LockKey, Vec) { + assert_eq!(lines.len(), 7); + if lines[0].chars().all(|c| c == '#') { + // lock + let mut pins = vec![0; 5]; + for row in 1..lines.len() { + let row_s = lines[row]; + for i in 0..row_s.len() { + if row_s.chars().nth(i) == Some('#') { + pins[i] = row + } + } + } + (LockKey::Lock, pins) + } else if lines[6].chars().all(|c| c == '#') { + // key + let mut pins = vec![5; 5]; + for row in (1..lines.len()).rev() { + let row_s = lines[row]; + for i in 0..row_s.len() { + if row_s.chars().nth(i) == Some('#') { + pins[i] = 6 - row + } + } + } + (LockKey::Key, pins) + } else { + panic!("not a lock or a key: {:?}", lines); + } +} + +fn parse(input: &str) -> LockPile { + let mut locks = Vec::new(); + let mut keys = Vec::new(); + let mut accum: Vec<&str> = Vec::new(); + for line in input.lines() { + if line == "" { + let (lk, pins) = parse_grid(&accum); + match lk { + LockKey::Lock => locks.push(pins), + LockKey::Key => keys.push(pins), + } + accum.clear(); + } else { + accum.push(line); + } + } + if accum.len() != 0 { + let (lk, pins) = parse_grid(&accum); + match lk { + LockKey::Lock => locks.push(pins), + LockKey::Key => keys.push(pins), + } + } + LockPile { keys, locks } +} + +fn test_lock_key(lock: &Vec, key: &Vec) -> bool { + !lock.iter().zip(key.iter()).any(|(lp, kp)| lp + kp > 5) +} + +#[aoc(day25, part1)] +pub fn part1(input: &str) -> i64 { + let lockpile = parse(input); + + lockpile + .locks + .iter() + .cartesian_product(lockpile.keys.iter()) + .filter(|(l, k)| test_lock_key(l, k)) + .count() as i64 +} + +#[aoc(day25, part2)] +pub fn part2(_input: &str) -> String { + "run the other solutions for day 25 part 2!".to_string() +} + +#[cfg(test)] +mod tests { + use super::*; + const EXAMPLE: &str = "##### +.#### +.#### +.#### +.#.#. +.#... +..... + +##### +##.## +.#.## +...## +...#. +...#. +..... + +..... +#.... +#.... +#...# +#.#.# +#.### +##### + +..... +..... +#.#.. +###.. +###.# +###.# +##### + +..... +..... +..... +#.... +#.#.. +#.#.# +#####"; + + #[test] + fn part1_example() { + assert_eq!(part1(EXAMPLE), 3); + } + + #[test] + fn part2_example() {} +} diff --git a/src/lib.rs b/src/lib.rs index 6cfecaf..ee2182e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -15,6 +15,7 @@ pub mod day21; pub mod day22; pub mod day23; pub mod day24; +pub mod day25; pub mod day3; pub mod day4; pub mod day5;