A live coding walkthrough of Advent of Code 2025 Day 2 using Rust. Covers parsing product ID ranges with the nom library, identifying invalid IDs (numbers made of repeated digit sequences), and solving both parts. Includes a refactor of Day 1's parser using nom combinators, debugging type inference issues with generics, and optimizing the Day 2 Part 2 solution using Rayon for parallel iteration — reducing runtime from ~75ms to ~13-20ms. Also demonstrates Rust-specific patterns like inclusive ranges, string slicing, iterator cycling with zip, and the all_consuming combinator.
•30m watch time