Day 18: Lavaduct Lagoon [AOC2023 Python] @0xdf
Day 18: Lavaduct Lagoon [AOC2023 Python]  @0xdf
Uploaded December 2023 | Updated November 2026, 1 day ago
For Advent of Code 2023 Day 18, I get a series of instructions for moving around a grid digging out a polygon trench. In each part, I need to find the total number of squares included in the trench once the internal points are dug out as well. In part 2, it's the same problem, but a different interpretation of the instructions so that the area gets enormous. I'll use the shoelace formula and Picks theorem to solve instantly.

Code 2023 AOC: gitlab.com/0xdf/aoc2023
Challenge Link: adventofcode.com/2023/day/10
Shoelace Formula: en.wikipedia.org/wiki/Shoelace_formula
Picks Theorem: en.wikipedia.org/wiki/Pick%27s_theorem

☕ Buy Me A Coffee: buymeacoffee.com/0xdf

[00:00] Part 1 description
[01:33] Strategy / Shoelace / Picks
[03:41] Prep
[04:09] Parse input to points
[06:41] Perimeter
[09:50] Shoelace
[10:49] Apply Pick's
[12:27] Solve part 1
[12:45] Part 2 description
[13:26] Clone part 1
[14:13] Updating parsing
[16:15] Solve part 2
[16:34] Summary

#adventofcode #python
Day 18: Lavaduct Lagoon [AOC2023 Python]Directory Traversal / File Read Into Zip with Python [HackTheBox Snoopy]Triple Knock [HackTheBox - Coding Challenge]Day 14 - One-Time Pad [Revival of Code 2023 - Advent of Code 2016]Introduction [Advent of Code 2024]Disk Fragmenter [Day 9 - Advent of Code 2024 - Python]Reassembling Werkzeugs Pin - Hacking Flask Debug Mode [Part 1]Keypad Conundrum [Day 21 - Advent of Code 2024 - Python]Modifying .NET Exe: Encrypt to Decrypt [HackTheBox Coder]Day 20 - Firewall Rules [Revival of Code 2023 - Advent of Code 2016]Day 5 - How About a Nice Game of Chess? [Revival of Code 2023 - Advent of Code 2016]Hacking the HackTheBox Code Editor
0xdf |

Day 18: Lavaduct Lagoon [AOC2023 Python]

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER