testing all permutations of operation order