1.

/**
* FWP, Ausgewählte Probleme aus dem ACM Programming Contest, WS09
* Problem: 11734 Big Number of Teams will Solve This
* Link: http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=117&page=show_problem&problem=2834
*
* @author Christoph Hausmann
* @version 0.1, 12/19/2009
*
* Method : Ad hoc
* Status : Accepted
* Runtime: 0.312
*/

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;


public class BigNumberofTeamswillSolveThis_11734 {
public static void main(String... args) throws NumberFormatException, IOException {
final BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

final int numberTests = Integer.parseInt(br.readLine());

for(int curTest = 1; curTest <= numberTests; curTest++) {
final String team = br.readLine();
final String judge = br.readLine();

String result = "";

if(team.equals(judge)) {
result = "Yes";
} else if(okWhenIgnoringSpaces(team,judge)) {
result = "Output Format Error";
}
else {
result = "Wrong Answer";
}

System.out.println("Case " + curTest + ": " + result);
}
}

private static boolean okWhenIgnoringSpaces(String team, String judge) {
team = team.replaceAll(" ", "");

return team.equals(judge);
}
}