A 1= team name, A2= team 1, A3= team 2...A7 = team;
B2 = Rand (), B3 = Rand () ... ……B7 = Rand ();
C 1= number of matches,
C2=IF(RANK(B2, B$2:B$7)>3, "first"&; Rank (B2, 2 yuan: 7 yuan)-3 & "Field"&; "Gone" and "No"&; Rank (B2, B$2:B$7) "field"&; "home")
Pull C2 to C7.
If you feel dissatisfied with the result, just press F9, hehe.
Column b is an auxiliary column. If you want to demonstrate, you can hide this column.