Skip to content

Commit 83b556a

Browse files
committed
Integrate Gaussian elimination solution in 2025 day 10 part 2
1 parent 2af2615 commit 83b556a

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/main/scala/eu/sim642/adventofcode2025/Day10.scala

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@ object Day10 {
8787
}
8888
}
8989

90+
/**
91+
* Solution, which performs Gaussian elimination and then brute forces free variables in their ranges.
92+
*/
9093
object GaussianEliminationPart2Solution extends Part2Solution {
9194
/*
9295
x0 x1 x2 x3 x4 x5
@@ -161,6 +164,6 @@ object Day10 {
161164

162165
def main(args: Array[String]): Unit = {
163166
println(Part1.sumFewestPresses(parseMachines(input)))
164-
println(Z3Part2Solution.sumFewestPresses(parseMachines(input)))
167+
println(GaussianEliminationPart2Solution.sumFewestPresses(parseMachines(input)))
165168
}
166169
}

src/test/scala/eu/sim642/adventofcode2025/Day10Test.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import org.scalatest.funsuite.AnyFunSuite
88
class Day10Test extends Suites(
99
new Part1Test,
1010
new NaivePart2SolutionTest,
11-
//new Z3Part2SolutionTest,
11+
new Z3Part2SolutionTest,
1212
new GaussianEliminationPart2SolutionTest,
1313
)
1414

0 commit comments

Comments
 (0)