General Discussions

Discuss any topics that are not product-specific here.

Advent of Code 2020 - BaseA Style (Day 12)

Jean-Balteryx
16 - Nebula
16 - Nebula

Discussion thread for day 12 of the Advent of Code : https://adventofcode.com/2020/day/12

16 REPLIES 16
peter_gb
9 - Comet

Iterative for me! Got in a pickle to start with but got there eventually!

Spoiler
12.png12_1.png

  

peter_gb
9 - Comet

I've also been enjoying making visualisations of these...!

Spoiler
12_1_img.png

12_2_img.png

  

 

danilang
19 - Altair
19 - Altair

Much easier than yesterday.  Interesting way to navigate.

 

Spoiler
w.png
Multirow for part one and iterative for part 2
m.png

Quite possibly the simplest and most elegant Iterative macro I've ever written.  It effectively gives a multi-column multirow formula by calculating all the dynamic values for the current row and pasting these into the next row.

Dan

NedHarding
7 - Meteor

I question their navigation computer!  Here is the path:

 

NedHarding_0-1607790837691.png

 

Spoiler
So obviously went spatial on part 2.  Unless you want to go the macro route, you need to fuse X & Y - so you might as well use spatial.

Still some tricks left though - The multi-row formula always produces a NULL spatial object, there isn't the equivalent of 0.  So I injected the 1st record in via a union, which also allowed me to set the initial waypoint.  But then you have to remember to detect that initial condition in the expression.  With a more complicated expression you could avoid injecting the record.

I could have re-written part 1 using spatial and eliminated a tool, but I didn't...

Workflow on github:  https://github.com/NedHarding/Advent2020

NedHarding_1-1607790922483.png

 

Jean-Balteryx
16 - Nebula
16 - Nebula

Went down the macro route but will give a try at multi-row for part 1 !

I've made more iterative macros in the last 12 days than since I started Alteryx ...

 

Workflow :

 

Spoiler
Capture d’écran 2020-12-12 à 21.47.48.png

Part 1 macro :

 

Spoiler
Capture d’écran 2020-12-12 à 21.44.55.png

Part 2 macro :

 

Spoiler
Capture d’écran 2020-12-12 à 21.46.05.png

 

Greg_Murray
12 - Quasar

The scratch paper on my desk is really starting to accumulate. I'm pretty impressed by Part 2 the multi-row solutions people are posting. 

Spoiler
Greg_Murray_0-1607807970500.png

Greg_Murray_1-1607808017658.png

T_Willins
14 - Magnetar
14 - Magnetar

Couldn't get the spatial to work, but will look at it later.  Realized after building iterative macro for part b could have made it simpler.

 

12b Iterative Macro.jpg

 

AOC 20.12 Workflow.jpg

 

Labels