Quant Memo
Coding/●●●●●

All orderings to execute a basket of trades

Given a basket of distinct child orders, list every ordering in which they could be executed. For a small basket you might want to simulate all execution sequences.

orders = ["X", "Y", "Z"]
-> 6 orderings: XYZ, XZY, YXZ, YZX, ZXY, ZYX

Return all n! permutations of the input.

Your answer

This one is open-ended. Work it through, then check your reasoning against the full solution.

More Coding questions