Random Link ¯\_(ツ)_/¯ | ||
Aug 23, 2025 | » | AoC 2024 Day 07: Bridge Repair
6 min; updated Aug 23, 2025
Parsing Each line represents a single equation, e.g., 292: 11 6 16 20. Part One needs to make a decision based on each line independently. Parsing each line into a data structure and yielding that should suffice. using System.Collections.Immutable; using System.Text.RegularExpressions; namespace AoC2024; public partial class BridgeRepair { public static IEnumerable<CalibrationEquation> Parse(string filePath) { using var inputReader = new StreamReader(filePath); string? line; while ((line = inputReader.ReadLine()) != null) { var numbers = InputLineRegex.... |
Feb 19, 2023 | » | 023. Non-Abundant Sums
9 min; updated Feb 19, 2023
#23 Non-abundant sums - Project Euler. projecteuler.net . Accessed Feb 19, 2023. Problem Statement A perfect number is a number for which the sum of its proper divisors is exactly equal to the number. For example, the sum of the proper divisors of \(28\) would be \(1 + 2 + 4 + 7 + 14 = 28\), which means that \(28\) is a perfect number.... |
Mar 16, 2022 | » | AoC 2021 Day 09: Smoke Basin
13 min; updated Mar 16, 2022
Multi-dimensional arrays using |