follow e.g one

(a1,a2) vs (b1,b2 )

a1,a2

a1,b1

a1,b2

a2,b1

a2,b2

b1,b2.

n add c1,c2

like abcd in full combination it

ABC BAC CAB DAB

ACB BCA CBA DBA

ABD BAD CAD DAC

ADB BDA CDA DCA

ACD BCD CBD DBC

ADC BDC CDB DCB

solves for

a) a1,a2 vs b1,b2 vs c1,c2

b) a1,a2 vs b1,b2 vs c1,c2 vs d1,d2

c) a1,a2 vs b1,b2 vs c1,c2 vs d1,d2, e1,e2 ....

replaces abc with a1 a2 b1 b2 c1 c2 d1 d2 e1 e2 that simple ....