You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
565 B
25 lines
565 B
import java.util.ArrayList;
|
|
|
|
public class Out {
|
|
static final ArrayList<String> output = new ArrayList<>();
|
|
|
|
private Out() { throw new IllegalStateException("Utility class"); }
|
|
|
|
public static void println(String string) {
|
|
output.add(string);
|
|
}
|
|
|
|
public static void println() {
|
|
println("");
|
|
}
|
|
|
|
public static String get() {
|
|
StringBuilder string = new StringBuilder();
|
|
for (String s : output) {
|
|
string.append(s);
|
|
string.append("\n");
|
|
}
|
|
return string.toString();
|
|
}
|
|
}
|