Discussion thread for day 4 of the Advent of Code - https://adventofcode.com/2023/day/4
Tried to refine, but not getting much better.
First day that requires a macro - this is going to quickly become normal I reckon!
@clmc9601 - very elegant - I tackled the inner macro differently but I see why yours works!
Very grateful to @patrick_digan , who showed me the magical use of the multirow formula tool during the Intcode fiasco of 2019
I did use what appears to be a useless summarize tool to figure out how many rows above I'd need to be counting. And I figured out the logic by modeling the sample data in Excel (whee, typing x into columns and then adding up and trying to discern a pattern!)
The logic, as I saw it, was that for a row above to add records to the current row, the number of cards generated for that row above must be greater than or equal to the numbers of rows above. For example, for 3 rows above, there need to be 3 or more generate cards to touch the current row. Not sure if it's the best way to solve this, and it did work and no macros. And my part 3 is efficient with only three tools (one of which isn't needed after the first run)
Fun to create an iterative macro after a long time
My solution.
Advent of Code Part 1. Feels a lot more messy than it should be
Is there a better feeling than switching your input from the example to the real and getting the answer right 1st time?
(even if you laboured over the example input for aaaaaaaages)
Part one only at this point! 😊
My solution:
Good iterative macro practice!
Fun Challenge.
I ended up using iterative macros for both parts
It was too soon for an iterative macro!
I post again with solution in yxdb.