I am trying to create a tidier code block to find elements and organise elements in a list based on a conditional statement (for each string in the selection list or ‘testlist’, if the string exists in the list of grid names ‘a’ add the grid curve).
I would like to try and reduce the codeblock by lacing the lists, avoiding a list of conditional statements or a loop. I haven’t had any success with adding “<1>” lacing to the lists in the conditional statement - I am wondering whether this is possible. I have also tried a more manual lacing attempt by creating a list of lists to test.
Any help or suggestions to tidy this solution up with code blocks much appreciated!