This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Discuss a wide range of topics! Questions about the Alteryx Platform should be directed to the appropriate Product discussion forum.
General Discussions has some can't miss conversations going on right now! From conversations about automation to sharing your favorite Alteryx memes, there's something for everyone. Make it part of your community routine!
Main workflow. Creating the seat pairs was for part 2 was long a took a little debugging. One missed tickbox on a multi-row grouping had me stumbling for a while.
A few notes on the solution:
- I used row and col fields to find seat pairings, but then combined those into a single seatid field before going into the macro. - I added ring of empty "." spaces around the room to avoid wraparound issues on the edges. - Once spaces have been given an ID, empty "." are not needed in the iteration checks, they always stay "." and don't affect seating choices so they're filtered out before going into the macros or working out the next seat in part 2.
Iterative Macro. Half of the tools here are just creating a proper escape for the iterations as opposed to pair matching.
Part 2. My macro isn't complicated, but the price I pay is time. Part 2 took 5 minutes in its entirety. I spilt it into 2 parts. 1 part in the main workflow figures out where each seat needs to check (brute force), and then the iterative macro does all of the iterations (again, very brute force).
i used my normal approach with these AOC problems using a single long string. It makes it fairly easy to work with and bebug, but It just isn't performant when you have to replicate the string a bunch. Glad this one's behind me solved. I'm sure the Alteryx Abacus would make it much more performant.
Quite happy with mine, my final solution makes up for the nightmare mis-read of part 1! Didn't resort to reddit or here today 🙂 I had to leave this for a while to go and work after part 1 - wasted an hour by misinterpreting the part one as look 8 seats in each direction, not 8 seats, 1 in each direction.... DOH!
Iterative macro for part 1, then an iterative to prepare for part 2 by looking for the next seat in each direction for each seat as this doesn't change.
Then a modification of my part 1 macro to solve part 2. <1 min so not too horrible either.