George Thomas
be0a6510d8
Use lazy text for test outputs
...
Simplifies encoding code slightly, and potentially saves a lot of time for failing tests. Plus we've always been using `T.show` in practice anyway, so it's an easy change to make.
2025-12-04 21:24:49 +00:00
George Thomas
f91824a6a9
Add some useful inputs to extraTests
2025-12-04 21:17:50 +00:00
George Thomas
2f35bd9251
Format
2025-12-04 21:17:50 +00:00
George Thomas
8f67916e1a
Add way to specify extra tests
2025-12-04 21:17:50 +00:00
George Thomas
0508947a65
Solve day 4 part 2
2025-12-04 20:00:53 +00:00
George Thomas
649f06821b
Add day 4 part 2 example output
2025-12-04 18:02:57 +00:00
George Thomas
9137e7cd66
Solve day 4 part 1
2025-12-04 18:02:57 +00:00
George Thomas
dea25e3359
Add some useful dependencies
2025-12-04 11:14:31 +00:00
George Thomas
0844d4af2f
Initialise day 4
2025-12-04 10:00:15 +00:00
George Thomas
beaacd3e03
Reformat
2025-12-04 09:53:37 +00:00
George Thomas
6727a0a301
Reformat flake outputs
2025-12-04 09:52:28 +00:00
George Thomas
7758ab39a8
Reformat flake inputs
2025-12-04 09:51:26 +00:00
George Thomas
23c0777425
Fix Rust Analyzer
...
Previously we had warnings about sysroot, and limited feedback. This fix is from the Crane docs section about building standard library crates.
2025-12-04 09:50:55 +00:00
George Thomas
a81d622125
Refactor day 1 to make more use of state monad
2025-12-03 17:52:23 +00:00
George Thomas
b9e886c4e4
Solve day 3 part 2
2025-12-03 17:13:47 +00:00
George Thomas
fde8efee8c
Add day 3 part 2 example output
2025-12-03 15:57:01 +00:00
George Thomas
2c1edfcfb6
Defer type errors
2025-12-03 15:56:56 +00:00
George Thomas
94c9838371
Add some useful extensions
2025-12-03 15:56:56 +00:00
George Thomas
f296e3d5a7
Solve day 3 part 1
2025-12-03 15:56:56 +00:00
George Thomas
b99bacc1e3
Initialise day 3
2025-12-03 11:18:04 +00:00
George Thomas
238e26dccf
Move all Rust stuff in to subdirectory
2025-12-02 18:38:21 +00:00
George Thomas
3a00dc568f
Rename Rust source folder
2025-12-02 18:38:09 +00:00
George Thomas
2950ff778e
Add simple Rust Crane project
...
The Nix code is taken from the Crane docs, and adapted for merging with the existing Haskell.Nix flake. The other files are from `cargo init`, with minor modifications, and `cargo generate-lockfile`.
The default dev shell contains tools for both languages.
We can now run `nix build .#rust` and `nix build .#haskell`, where the latter was previously `nix build .#aoc:exe:aoc`.
2025-12-02 16:42:44 +00:00
George Thomas
83b994965d
Use consistent naming convention for puzzles
2025-12-02 15:22:21 +00:00
George Thomas
f0c2b8ca02
Move code out to separate modules
2025-12-02 15:19:11 +00:00
George Thomas
b7c17c2d32
Sort dependencies
2025-12-02 15:05:31 +00:00
George Thomas
3b093aac23
Use named directory for Haskell source
...
Makes way for other languages.
2025-12-02 14:59:15 +00:00
George Thomas
ef54d8ffa9
Inline main test function
2025-12-02 14:35:17 +00:00
George Thomas
40f7a8ee9a
Format
2025-12-02 14:27:14 +00:00
George Thomas
60acecb993
Make test tree reflect directory tree
2025-12-02 14:26:45 +00:00
George Thomas
0d236a2f2c
Add deepseq as a dependency
...
Useful for performance debugging.
2025-12-02 13:33:38 +00:00
George Thomas
c0504964e3
Refactor to unify day 2 parts 1 and 2
...
This doesn't noticeably affect the run time.
2025-12-02 13:33:11 +00:00
George Thomas
fe3493aa86
Solve day 2 part 2
...
This is pretty naive but runs in less than a second when compiled.
2025-12-02 13:32:48 +00:00
George Thomas
6f3855ce4b
Minor refactor
2025-12-02 11:22:17 +00:00
George Thomas
ce3e586e0c
Refactor to use existential
2025-12-02 11:21:04 +00:00
George Thomas
b19c02811e
Refactor to use field puns
2025-12-02 11:20:48 +00:00
George Thomas
c25b6062c6
Refactor to use wildcard
2025-12-02 11:20:00 +00:00
George Thomas
bd4d350e76
Format
2025-12-02 11:15:49 +00:00
George Thomas
3601933bd0
Simplify part solver types
...
This also gives us the flexibility to have all tests passing when only part 1 is complete.
2025-12-02 11:14:54 +00:00
George Thomas
778249c66b
Remove unused field
2025-12-02 11:09:34 +00:00
George Thomas
d4ad05ba50
Solve day 2 part 1
2025-12-02 10:54:12 +00:00
George Thomas
6e8b5dff01
Reformat
2025-12-02 10:46:06 +00:00
George Thomas
72b0132058
Show parse errors
2025-12-02 10:45:45 +00:00
George Thomas
9ca3840d5f
Fix example input formatting
2025-12-02 10:21:11 +00:00
George Thomas
0d9976bfb4
Reformat
2025-12-02 09:38:31 +00:00
George Thomas
90c5e2f0b2
Force Tasty to use colours in GHCID
2025-12-02 09:30:39 +00:00
George Thomas
1a75e65987
Add initial data for day 2
2025-12-02 09:20:03 +00:00
George Thomas
d88e2a26c6
Use Text
2025-12-02 09:11:42 +00:00
George Thomas
a72342fb11
Refactor to use Megaparsec
2025-12-02 09:08:43 +00:00
George Thomas
b1bd83f089
Minor refactor
2025-12-02 08:56:07 +00:00