Don't forget to register for our panel discussion with Dean Stoecker, Amy Holland, and Mark Frisch occurring next Wednesday, June 1!

2022-05-26 Updates: Email: If you're not seeing emails be delivered from the Community, please check your spam and mark the Community emails as not junk. Thank you for your patience.

General Discussions

Discuss any topics that are not product-specific here.

Advent of Code 2020 - BaseA Style (Day 8)

Jean-Balteryx
16 - Nebula
16 - Nebula

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

20 REPLIES 20
jdunkerley79
ACE Emeritus
ACE Emeritus

This is far too close to IntCode...

Spoiler
Part 1: simple iterative macro
Part 2: batch macro switching nop and jmp one at a time

jdunkerley79_0-1607407658542.png

 

jdunkerley79_2-1607407703267.png

 

jdunkerley79_4-1607407752923.png

 


 

T_Willins
14 - Magnetar
14 - Magnetar

First part was straightforward; second part took a little longer to debug and get the Join correct at the end.  

 

Spoiler
WorkflowWorkflowBatch MacroBatch Macro

 

Iterative MacroIterative Macro

 

 

 

joshbennett
11 - Bolide

Looking at @jdunkerley79 and @T_Willins solutions, I may have overengineered my macro a bit!

 

Part 1:

Spoiler
Solution:
joshbennett_2-1607429854130.png

 


 




Iterative Macro:

joshbennett_1-1607429838032.png

 


 

 

Part 2:

Spoiler
Solution:
joshbennett_3-1607429862160.png

 



Batch Macro:
joshbennett_4-1607429874377.png

 



In the above batch macro, I used the same iterative macro from part 1, though I was not pleased with the performance results so am looking forward to looking through each of the other solutions to understand how I may have been able to do this more efficiently!


 

 

dsmdavid
11 - Bolide

Nested iteratives... as @jdunkerley79 says... IntCode, this year I'm ready for you. Or not.

Spoiler
Alteryx_Day_08.png

 

dsmdavid
11 - Bolide

Nested iterative... as @jdunkerley79 says... this year I'm ready for the IntCode. Or not.

Spoiler
Alteryx_Day_08.png
OllieClarke
14 - Magnetar
14 - Magnetar

Not especially happy with my approach as it took a *long* time to solve part 2. Here it is anyway though

Spoiler
Went with a batch macro containing an iterative, to brute force solve the puzzle. However, the fact that I was reading and writing a file every iteration, and using joins made it slooooow. 
workflowworkflowPart 1 iterative macroPart 1 iterative macroPart 2 iterative macroPart 2 iterative macroPart 2 batch macro containing part 2 iterativePart 2 batch macro containing part 2 iterative
peter_gb
8 - Asteroid

Closed a container, alteryx crashed, stuck in an endless loop of open alteryx hang on file recovery... Ironic..

Spoiler
8ffs.png

 Managed similar to above solutions, iterative to solve, batch to feed in swapped instructions. Definitely could be tidier but got the stars so happy for now...

Spoiler
8.png

danilang
18 - Pollux
18 - Pollux

Similar to above.  Iterative to model the CPU and batch to modify the inputs 

 

Spoiler
mainmain

CPU iterativeCPU iterative

batch input fixerbatch input fixer

 Dan

Balders
11 - Bolide

Very happy with mine, I managed to use append fields over joins which I think helped with performance and managed to keep tools to a minimum in the first macro. The second macro needed a few extra tools to exit its loop at the right point.

Spoiler
Main Workflow
Screenshot 2020-12-08 142535.png

Macro 1Screenshot 2020-12-08 142602.png

Macro 2Screenshot 2020-12-08 142628.png

 

Labels