You can prove three-term commutativity from two-term (I did it years ago, I think it looked something like this[1]), so the ordering doesn't matter.
[1] https://math.stackexchange.com/questions/785576/prove-the-co...
[1] https://math.stackexchange.com/questions/785576/prove-the-co...
Or applied to the programming example, the statements:
1. Server.accept
2. Client.connect
3. File.write # write to completely unrelated file
123 = 312 ≠ 321.