Skip to content

Commit

Permalink
Link to the days
Browse files Browse the repository at this point in the history
  • Loading branch information
fwcd committed Jan 31, 2024
1 parent c0bcdcc commit e148337
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 34 deletions.
58 changes: 29 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,31 @@

My solutions to the [Advent of Code 2023](https://adventofcode.com/2023), written in 25 different programming languages.

- [x] Day 01: [C](day01/src/day01.c)
- [x] Day 02: [COBOL](day02/src/day02.cob)
- [x] Day 03: [ALGOL 60](day03/src/day03.alg)
- [x] Day 04: [Nix](day04/src/day04.nix)
- [x] Day 05: [B](day05/src/day05.b) ([readme](day05/README.md))
- [x] Day 06: [LLVM IR](day06/src/day06.ll)
- [x] Day 07: [Prolog](day07/src/day07.pl)
- [x] Day 08: [Objective-C](day08/src/day08.m)
- [x] Day 09: [Curry](day09/src/Day09.curry)
- [x] Day 10: [Java](day10/src/Day10.java)
- [x] Day 11: [Crystal](day11/src/day11.cr)
- [x] Day 12: [MoonScript](day12/src/day12.moon)
- [x] Day 13: [Vala](day13/src/day13.vala)
- [x] Day 14: [Go](day14/src/day14.go)
- [x] Day 15: [Brainfuck](day15/src/part1.bf), [D](day15/src/part2.d)
- [x] Day 16: [Zig](day16/src/day16.zig)
- [x] Day 17: [PHP](day17/src/day17.php)
- [x] Day 18: [C++](day18/src/day18.cpp)
- [x] Day 19: [Swift](day19/src/day19.swift)
- [x] Day 20: [Kotlin/Native](day20/src/day20.kt)
- [x] Day 21: [C#](day21/src/day21.cs)
- [x] Day 22: [Rust](day22/src/day22.rs)
- [x] Day 23: [Ruby](day23/src/day23.rb)
- [ ] Day 24: [Haskell](day24/src/Day24.hs)
- [ ] Day 25: [Python](day25/src/day25.py)
- [x] Day [01](day01): [C](day01/src/day01.c)
- [x] Day [02](day02): [COBOL](day02/src/day02.cob)
- [x] Day [03](day03): [ALGOL 60](day03/src/day03.alg)
- [x] Day [04](day04): [Nix](day04/src/day04.nix)
- [x] Day [05](day05): [B](day05/src/day05.b) ([readme](day05/README.md))
- [x] Day [06](day06): [LLVM IR](day06/src/day06.ll)
- [x] Day [07](day07): [Prolog](day07/src/day07.pl)
- [x] Day [08](day08): [Objective-C](day08/src/day08.m)
- [x] Day [09](day09): [Curry](day09/src/Day09.curry)
- [x] Day [10](day10): [Java](day10/src/Day10.java)
- [x] Day [11](day11): [Crystal](day11/src/day11.cr)
- [x] Day [12](day12): [MoonScript](day12/src/day12.moon)
- [x] Day [13](day13): [Vala](day13/src/day13.vala)
- [x] Day [14](day14): [Go](day14/src/day14.go)
- [x] Day [15](day15): [Brainfuck](day15/src/part1.bf), [D](day15/src/part2.d)
- [x] Day [16](day16): [Zig](day16/src/day16.zig)
- [x] Day [17](day17): [PHP](day17/src/day17.php)
- [x] Day [18](day18): [C++](day18/src/day18.cpp)
- [x] Day [19](day19): [Swift](day19/src/day19.swift)
- [x] Day [20](day20): [Kotlin/Native](day20/src/day20.kt)
- [x] Day [21](day21): [C#](day21/src/day21.cs)
- [x] Day [22](day22): [Rust](day22/src/day22.rs)
- [x] Day [23](day23): [Ruby](day23/src/day23.rb)
- [ ] Day [24](day24): [Haskell](day24/src/Day24.hs)
- [ ] Day [25](day25): [Python](day25/src/day25.py)

## Development

Expand All @@ -50,11 +50,11 @@ Every day is packaged up to take exactly one command-line argument, the input fi
## Lessons Learned

- Visualize the input with GraphViz (day 8, 20, 23)
- Some puzzles are actually reverse-engineering exercises and rely on undocumented input constraints to be solved efficiently or even feasibly at all (day 8, 20, 23)
- Take the [LCM](https://en.wikipedia.org/wiki/Least_common_multiple) to solve cycle alignment problems (day 8, 20)
- Visualize the input with GraphViz (day [8](day08), [20](day20), [23](day23))
- Some puzzles are actually reverse-engineering exercises and rely on undocumented input constraints to be solved efficiently or even feasibly at all (day [8](day08), [20](day20), [23](day23))
- Take the [LCM](https://en.wikipedia.org/wiki/Least_common_multiple) to solve cycle alignment problems (day [8](day08), [20](day20))
- If there are offsets, use the [CRT](https://en.wikipedia.org/wiki/Chinese_remainder_theorem) ([like in previous years](https://github.com/fwcd/advent-of-code-2020/blob/18c3ba9820cb52627366a632ccaab233a6d9f563/day13/src/day13.c#L39-L59))
- Binary counters can elegantly be modeled as chains of flip flop (day 20)
- Binary counters can elegantly be modeled as chains of flip flop (day [20](day20))

## Previous years

Expand Down
13 changes: 8 additions & 5 deletions README.md.gyb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
if additional_notes:
s += f' {additional_notes}'
return s

def day_links(ds):
return f"day {', '.join(f'[{d}](day{d:02})' for d in ds)}"
}%
<!-- Automatically generated from README.md.gyb, do not edit directly! -->

Expand All @@ -28,7 +31,7 @@ My solutions to the [Advent of Code 2023](https://adventofcode.com/2023), writte

% for i, day in enumerate(days):
% if day:
- [${'x' if day.get('completed', False) else ' '}] Day ${f'{i + 1:02}'}: ${', '.join(format_solution(part) for part in day.get('parts', [day]))}
- [${'x' if day.get('completed', False) else ' '}] Day [${f'{i + 1:02}'}](day${f'{i + 1:02}'}): ${', '.join(format_solution(part) for part in day.get('parts', [day]))}
% end
% end

Expand All @@ -50,11 +53,11 @@ Every day is packaged up to take exactly one command-line argument, the input fi

## Lessons Learned

- Visualize the input with GraphViz (day 8, 20, 23)
- Some puzzles are actually reverse-engineering exercises and rely on undocumented input constraints to be solved efficiently or even feasibly at all (day 8, 20, 23)
- Take the [LCM](https://en.wikipedia.org/wiki/Least_common_multiple) to solve cycle alignment problems (day 8, 20)
- Visualize the input with GraphViz (${day_links([8, 20, 23])})
- Some puzzles are actually reverse-engineering exercises and rely on undocumented input constraints to be solved efficiently or even feasibly at all (${day_links([8, 20, 23])})
- Take the [LCM](https://en.wikipedia.org/wiki/Least_common_multiple) to solve cycle alignment problems (${day_links([8, 20])})
- If there are offsets, use the [CRT](https://en.wikipedia.org/wiki/Chinese_remainder_theorem) ([like in previous years](https://github.com/fwcd/advent-of-code-2020/blob/18c3ba9820cb52627366a632ccaab233a6d9f563/day13/src/day13.c#L39-L59))
- Binary counters can elegantly be modeled as chains of flip flop (day 20)
- Binary counters can elegantly be modeled as chains of flip flop (${day_links([20])})

## Previous years

Expand Down

0 comments on commit e148337

Please sign in to comment.