Every Debate Pairing in the Tournament
Problem
A school debate tournament has several clubs. Every pair of clubs debates twice: once with the first club arguing the affirmative side and once with it arguing the negative side. Table `clubs` has a single column `club_name`.
List all the debate pairings. A pairing names the affirmative club and the negative club, and a club never debates itself.
Return the columns `affirmative` and `negative`.
Tables
Example rows — the live problem includes the full dataset.
clubs
| club_name |
|---|
| Northgate |
| Riverside |
| Hilltop |
Expected output
Your answer should return 6 rows with the columns affirmative, negative.
Starter code (SQL)
SELECT *
FROM clubs;Solve this SQL question free
Write SQL and run it instantly in your browser — even on your phone. No signup needed to try.
Solution & explanation
Create a free account to unlock the optimal solution, a step-by-step explanation, and the hidden test cases that grade your answer.
Sign up free to unlock