C++ Data Structure to do this?
I have a class called logic which holds a single criteria to evaluate. A different object can have up to 20 of these criteria. I currently have an array containing multiple of these Logic classes. I can loop through the array and call evaluate on all of the Logic classes, then AND all of the results together to get a final result, which has been working. However, I am now needing to not only AND the results, but also OR. Is there a data structure to define something like (LOGIC1 && LOGIC2) || LOGIC3 that could link how these classes relate better than an array? The only criteria is that it has to be easy to ready when defining the structure, so something like this: