import java.io.*;
import java.util.*;

public class TestGen {
	public static void main(String[] args) {
		new TestGen().run();
	}

	BufferedReader br;
	StringTokenizer in;
	PrintWriter out;

	public String nextToken() throws IOException {
		while (in == null || !in.hasMoreTokens()) {
			in = new StringTokenizer(br.readLine());
		}
		return in.nextToken();
	}

	public int nextInt() throws IOException {
		return Integer.parseInt(nextToken());
	}

	public long nextLong() throws IOException {
		return Long.parseLong(nextToken());
	}

	public double nextDouble() throws IOException {
		return Double.parseDouble(nextToken());
	}

	int tNumber;

	Random rnd;

	void print(int n) throws IOException {
		if (tNumber < 10) {
			out = new PrintWriter("../tests/0" + tNumber);
		} else {
			out = new PrintWriter("../tests/" + tNumber);
		}
		tNumber++;
		out.println(n);
		out.close();
	}

	void genSimple() throws IOException {
		PrintWriter out;
		out = new PrintWriter("../preliminary/01");
		out.println("3");
		out.close();
	}

	public void generate() throws IOException {
		new File("../preliminary").mkdir();
		new File("../tests").mkdir();
		tNumber = 1;
		rnd = new Random(239);
		genSimple();
		print(1);
		print(2);
		print(4);
		print(5);
		for (int i = 0; i < 8; i++) {
			print(rnd.nextInt(41) + 60);
		}
		for (int i = 0; i < 5; i++) {
			print(rnd.nextInt(101) + 900);
		}
		for (int i = 0; i < 3; i++) {
			print(rnd.nextInt(500) + 6000);
		}
	}

	public void run() {
		try {
			generate();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
			System.exit(1);
		}
	}
}