import java.io.*;
// System.out.println();

public class P5
{
    public static void main (String[] args) throws IOException
    {

	PrintWriter output = new PrintWriter (new FileWriter ("OUT5.txt"));

	output.println ((int) (Math.random () * 5));
	output.println ((int) (Math.random () * 5));
	output.println ((int) (Math.random () * 5));
	output.println ((int) (Math.random () * 5));
	output.print ((int) (Math.random () * 5));

	output.close ();
    }
}



