this post was submitted on 01 Dec 2023
18 points (100.0% liked)

NotAwfulTech

386 readers
4 users here now

a community for posting cool tech news you don’t want to sneer at

non-awfulness of tech is not required or else we wouldn’t have any posts

founded 1 year ago
MODERATORS
 

Rules: no spoilers.

The other rules are made up as we go along.

Share code by link to a forge, home page, pastebin (Eric Wastl has one here) or code section in a comment.

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 2 points 1 year ago (1 children)

Day 17: Clumsy Crucible

Intimidating at first, so I went shopping for christmas presents first, which engaged my brain juices.

[Language: jq]https://github.com/zogwarg/advent-of-code/blob/main/2023/jq/17-b.jq

In hindsight this is is searching for the shortest path in a graph, making sure that each square is actually two nodes, for when approached vertically or horizontally. My shcool days are distant now, and i wonder how far from optimal my implementation is ^^.

Part two was only a small edit from part one for me, and the code actually ran faster! from ~45s -> ~20s.

[–] [email protected] 2 points 1 year ago

My part b code ran slower :(