Welcome Solution
Well, that was kind of confusing. You kind of had to read more carefully to realise that there were an unknown number data sets, and that each data set had a number - a number which determined how many times to loop through and print out 'We're so excited!!'.
import java.util.*;
import java.io.*;
import static java.lang.System.*;
public class Main {
public static void main(String[]args) throws IOException {
Scanner sc = new Scanner(System.in);
while (sc.hasNextInt()) { //unknown sets of numbers/data sets
int T = sc.nextInt();
for (int i = 0; i < T; i++) { //loop through T times
out.printf("We're so excited!!\n"); //print String T times
}
out.printf("\n"); //newline for each data set
}
}
}
Okay, enough input blah blah blah. Let's actually do some math.