I was wondering what data structure (built-in or not) would be optimal for accessing data that takes 5 conditions as an input.
For example:
if (cond_a == 2) & (cond_b == 3) ... (cond_e == 6):
value = 5
I am looking primarily for speed rather than being memory efficient. There are no relationships between the 5 conditions (they are independent of one another). However, an item can have multiple values for each condition - the data structure would return an iterable of values.
I was considering using nested ordered dictionaries (5 levels deep) - is there a better option?
edit - there may not necessarily be a unique value for all combinations of the 5 conditions. For certain combinations of conditions, changing one condition within that combination may not change the final value.