That sounds like a build of a triangular array, and that's more than a beginner's code, imo. Maybe by late November though...
If a triangular array is what you need, you can start out with two nested for loops, one for each team. The inner for loop will start with one team number greater than the outer team number (or letter).
Then the two players will have their own two nested for loops, inside the above two - one for each team's players. Here, the inner for loop will begin with zero, since you want player 1 to play against player 1 from the opposing team:
Code:
for each team1
for each team2 above team2 in number //avoid team1 plays team1
print out team names: team 1 vs. team 2
for each player1 starting with zero
for each player2, starting with zero
print out p1 vs. p2 numbers
print newline
end for each player1
print newline
end of each team2
end for each team1
The above gives you a tapering array print out sorted by team vs team, and then by the individual players match ups. It looks "odd", but it's right.
I don't know if that's what you want to do or not. I've never heard of anyone doing this, in a programming forum.
This is an example of the output, for 3 teams, named "A" through C, with 6 numbered players 1 - 6
Code:
Teams: A vs. B:
1 vs 1 1 vs 2 1 vs 3 1 vs 4 1 vs 5 1 vs 6
2 vs 2 2 vs 3 2 vs 4 2 vs 5 2 vs 6
3 vs 3 3 vs 4 3 vs 5 3 vs 6
4 vs 4 4 vs 5 4 vs 6
5 vs 5 5 vs 6
6 vs 6
Teams: A vs. C:
1 vs 1 1 vs 2 1 vs 3 1 vs 4 1 vs 5 1 vs 6
2 vs 2 2 vs 3 2 vs 4 2 vs 5 2 vs 6
3 vs 3 3 vs 4 3 vs 5 3 vs 6
4 vs 4 4 vs 5 4 vs 6
5 vs 5 5 vs 6
6 vs 6
Teams: B vs. C:
1 vs 1 1 vs 2 1 vs 3 1 vs 4 1 vs 5 1 vs 6
2 vs 2 2 vs 3 2 vs 4 2 vs 5 2 vs 6
3 vs 3 3 vs 4 3 vs 5 3 vs 6
4 vs 4 4 vs 5 4 vs 6
5 vs 5 5 vs 6
6 vs 6
It looks like player 1 plays more matches than anyone else, but they all play the same number of matches.
Is this what you need for output, however?