import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class Main {
	public static void main(String args[]) {
		InputStream intputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(intputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskA solver = new TaskA();
		solver.solve(in, out);
		out.close();
	}

	static class TaskA {
		public void solve(InputReader in, PrintWriter out) {
			out.println(25);
		}
	}

	static class InputReader {
		public BufferedReader reader;
		public StringTokenizer tokenizer;

		public InputReader(InputStream stream) {
			reader = new BufferedReader(new InputStreamReader(stream), 32768);
			tokenizer = null;
		}

		public String next() {
			while (tokenizer == null || !tokenizer.hasMoreTokens()) {
				try {
					tokenizer = new StringTokenizer(reader.readLine());
				} catch (IOException e) {
					throw new RuntimeException(e);
				}
			}
			return tokenizer.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public String nextLine() {
			try {
				return reader.readLine();
			} catch (IOException e) {
				return null;
			}
		}
	}
}


import java.io.*;
import java.util.*;
import java.math.*;
import static java.lang.Math.*;
import static java.lang.Integer.parseInt;
import static java.lang.Long.parseLong;
import static java.lang.Double.parseDouble;
import static java.lang.String.*;

public class Main {

    public static void main(String[] args) throws IOException {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
                                            //(new FileReader("input.in"));
        StringBuilder out = new StringBuilder();
        StringTokenizer tk;

        long n = parseLong(in.readLine());

        System.out.println("25");
    }

}


import java.util.Scanner;

/**
 * Created by mmaikovych on 18.02.16.
 */
public class EER_A {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        scanner.nextLine();
        System.out.println(25);
    }
}


import java.util.*;
public class ProA {
	static long n;

	public static void main(String[] args) {
		Scanner in=new Scanner(System.in);
		n=in.nextLong();
		System.out.println(25);
	}
}


import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.math.BigInteger;
import java.util.StringTokenizer;

public class A {

	static StringTokenizer st;
	static BufferedReader br;
	static PrintWriter pw;
	public static void main(String[] args) throws IOException {
		br = new BufferedReader(new InputStreamReader(System.in));
		pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
		BigInteger a = new BigInteger(next());
		System.out.println(BigInteger.valueOf(5).modPow(a, BigInteger.valueOf(100)));
		pw.close();
	}
	private static int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	private static long nextLong() throws IOException {
		return Long.parseLong(next());
	}
	private static double nextDouble() throws IOException {
		return Double.parseDouble(next());
	}
	private static String next() throws IOException {
		while (st==null || !st.hasMoreTokens())
			st = new StringTokenizer(br.readLine());
		return st.nextToken();
	}
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Madi
 */
public class A630 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String s = sc.nextLine();
        System.out.println("25");
    }
}


/*
 * The MIT License
 *
 * Copyright 2016 Mouad NACIRI <mouadnaciri1@gmail.com>.
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 */

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.IOException;
import java.util.StringTokenizer;

/**
 *
 * @author NACIRI Mouad <mouadnaciri1@gmail.com>
 * @version 1.5.1
 */

public class MainA {
    /* VIP, DON'T TOUCH!! */
    static StringTokenizer ST;
    static BufferedReader IN;
    static BufferedWriter OUT;
    static {
        IN = new BufferedReader(new InputStreamReader(System.in));
        OUT = new BufferedWriter(new OutputStreamWriter(System.out));
    }

    public static void main(String[] args) throws IOException {

        pl("25");
        cAll();
    }

    //IO stuff...
    static void ll() throws IOException { ST = new StringTokenizer(nlnt()); }
    static void ll(String del) throws IOException { ST = new StringTokenizer(nlnt(), del); }
    static void ll(String s, String del) throws IOException { ST = new StringTokenizer(s, del); }
    static void ll(String s, char c) throws IOException { ST = new StringTokenizer(s); }

    static int tlen() { return ST.countTokens(); }
    static boolean hn() { return ST.hasMoreTokens(); }
    static String n() throws IOException { return ST.nextToken(); }
    static String nln() throws IOException {
        String l;
        while((l = IN.readLine()) != null && l.trim().length() == 0) {}
        return l;
    }
    static String nlnt() throws IOException {
        String l;
        while((l = IN.readLine()) != null && (l = l.trim()).length() == 0) {}
        return l;
    }
    static boolean nbl() throws IOException { return Boolean.parseBoolean(ST.nextToken()); }
    static byte nb() throws IOException { return Byte.parseByte(ST.nextToken()); }
    static byte nb(int radix) throws IOException { return Byte.parseByte(ST.nextToken(), radix); }
    static double nd() throws IOException { return Double.parseDouble(ST.nextToken()); }
    static float nf() throws IOException { return Float.parseFloat(ST.nextToken()); }
    static int ni() throws IOException { return Integer.parseInt(ST.nextToken()); }
    static int ni(int radix) throws IOException { return Integer.parseInt(ST.nextToken(), radix); }
    static long nl() throws IOException { return Long.parseLong(ST.nextToken()); }
    static long nl(int radix) throws IOException { return Long.parseLong(ST.nextToken(), radix); }
    static short ns() throws IOException { return Short.parseShort(ST.nextToken()); }
    static short ns(int radix) throws IOException { return Short.parseShort(ST.nextToken(), radix); }

    static void p(String s) throws IOException { OUT.write(s); }
    static void p(char c) throws IOException { OUT.write(c); }
    static void p(char s[]) throws IOException { OUT.write(s); }
    static void pl(String s) throws IOException { OUT.write(s); OUT.newLine(); }
    static void pl(char c) throws IOException { OUT.write(c); OUT.newLine(); }
    static void pl(char s[]) throws IOException { OUT.write(s); OUT.newLine(); }
    static void pl() throws IOException { OUT.newLine(); }
    static void cAll() throws IOException { IN.close(); OUT.close(); }

}


import java.io.*;
import static java.lang.Math.*;

import java.lang.reflect.Array;
import java.util.*;
import java.lang.*;

public class Main {
    final static boolean debug = false;
    final static String fileName = "";
    final static boolean useFiles = false;

    public static void main(String[] args) throws FileNotFoundException {
        PrintWriter writer = new PrintWriter(System.out);
        new Task(new InputReader(System.in), writer).solve();
        writer.close();
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

    public long nextLong() {
        return Long.parseLong(next());
    }

    public byte nextByte() {
        return Byte.parseByte(next());
    }
}

class Task {
    public void solve() {
        out.println(25);
    }

    private InputReader in;
    private PrintWriter out;

    Task(InputReader in, PrintWriter out) {
        this.in = in;
        this.out = out;
    }
}


import java.io.*;

public class Main {
    private StreamTokenizer in;
    private PrintWriter out;

    public static void main(String[] args) throws IOException {
        //long time = System.currentTimeMillis();

        new Main().run();
        //time = System.currentTimeMillis() - time;
        //System.out.println(time + " ms");

    }

    private void run() throws IOException {
        //in = new StreamTokenizer(new BufferedReader(new InputStreamReader(new FileInputStream("input.txt"))));
        //BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream("input.txt")));
        //out = new PrintWriter(new File("output.txt"));

        in = new StreamTokenizer(new BufferedReader(new InputStreamReader(System.in)));
        //BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        out = new PrintWriter(new OutputStreamWriter(System.out));
        out.print(25);

        out.flush();

    }

    int nextInt() throws IOException {
        in.nextToken();
        return (int) in.nval;
    }
}


import java.io.InputStreamReader;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;
import java.math.BigInteger;
import java.util.Arrays;
/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Erasyl Abenov
 *
 *
 */
public class Main {
    public static void main(String[] args) throws IOException {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
            try (PrintWriter out = new PrintWriter(outputStream)) {
                TaskB solver = new TaskB();
                solver.solve(1, in, out);
            }
    }
}
class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) throws IOException{
        String n = in.next();
        out.println(25);
    }
}

class InputReader {
    private final BufferedReader reader;
    private StringTokenizer tokenizer;
    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream));
        tokenizer = null;
    }

    public String nextLine() {
        try {
            return reader.readLine();
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            tokenizer = new StringTokenizer(nextLine());
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
    public BigInteger nextBigInteger(){
        return new BigInteger(next());
    }
    public long nextLong() {
        return Long.parseLong(next());
    }
    public double nextDouble() {
        return Double.parseDouble(next());
    }
}


import java.io.*;
import java.util.*;
public class a {
public static void main(String[] args) throws IOException {
	input.init(System.in);
	PrintWriter out = new PrintWriter(System.out);
	long n = input.nextLong();
	if(n == 1) out.println(5);
	else out.println(25);
	out.close();
}

public static class input {
	static BufferedReader reader;
	static StringTokenizer tokenizer;

	static void init(InputStream input) {
		reader = new BufferedReader(new InputStreamReader(input));
		tokenizer = new StringTokenizer("");
	}

	static String next() throws IOException {
		while (!tokenizer.hasMoreTokens())
			tokenizer = new StringTokenizer(reader.readLine());
		return tokenizer.nextToken();
	}

	static int nextInt() throws IOException {
		return Integer.parseInt(next());
	}

	static double nextDouble() throws IOException {
		return Double.parseDouble(next());
	}

	static long nextLong() throws IOException {
		return Long.parseLong(next());
	}
}
}


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

public class A {
    public static void main(String[] args) throws Exception {
	// TODO Auto-generated method stub
	BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
	PrintWriter out = new PrintWriter(System.out);
	String s = bf.readLine();
	out.println(25);

	out.flush();
	out.close();

    }
}


import java.util.*;
public class TwentyFive {

	public static void main(String[] args)
	{
		System.out.println("25");
	}
}


import java.io.BufferedReader;
import java.io.Closeable;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.StringTokenizer;

public class A {

	public static void main(String[] args) {
		try (final Scanner sc = new Scanner(System.in)) {
			System.out.println(25);
		}
	}

	public static class Scanner implements Closeable {
		private BufferedReader br;
		private StringTokenizer tok;

		public Scanner(InputStream is) {
			br = new BufferedReader(new InputStreamReader(is));
		}

		private void getLine() {
			try {
				while (!hasNext()) {
					tok = new StringTokenizer(br.readLine());
				}
			} catch (IOException e) { /* ignore */
			}
		}

		private boolean hasNext() {
			return tok != null && tok.hasMoreTokens();
		}

		public String next() {
			getLine();
			return tok.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public void close() {
			try {
				br.close();
			} catch (IOException e) { /* ignore */
			}
		}
	}
}


/*
 * Code Author: Sanket Udgirkar.
 * DA-IICT
 */
import java.util.*;
import java.io.*;
public class Tester
{
	public static long mod=(long)1e9+7;

	public static void main(String[] args)
	{
		InputReader s=new InputReader(System.in);
        OutputStream outputStream = System.out;
        //PrintWriter out=new PrintWriter(outputStream);

       String str=s.nextLine();
       System.out.println("25");

        //out.close();
	}

	static long gcd(long a,long b)
	{
		if(b==0)
			return a;
		a%=b;
		return gcd(b,a);
	}

	static long exp(long a, long b)
	{
		if(b==0)
			return 1;
		if(b==1)
			return a;
		if(b==2)
			return a*a;

		if(b%2==0)
			return exp(exp(a,b/2),2);
		else
			return a*exp(exp(a,(b-1)/2),2);
	}

	static class Pair implements Comparable<Pair>
	{
		long x,f;
		Pair(long ii, long cc)
		{
			x=ii;
			f=cc;
		}

		public int compareTo(Pair o)
		{
			return Long.compare(this.x, o.x);
		}

	}

    public static class InputReader
    {
    	public BufferedReader reader;
    	public StringTokenizer tokenizer;

    	public InputReader(InputStream inputstream)
    	{
    	      reader = new BufferedReader(new InputStreamReader(inputstream));
    	      tokenizer = null;
    	}

    	public String nextLine()
    	{
    	    String fullLine=null;
    	    while (tokenizer == null || !tokenizer.hasMoreTokens())
    	    {
    	        try {
    	              fullLine=reader.readLine();
    	            }
    	        catch (IOException e)
    	        {
    	              throw new RuntimeException(e);
    	        }
    	        return fullLine;
    	     }
    	     return fullLine;
    	}
    		public String next()
    		{
    	      while (tokenizer == null || !tokenizer.hasMoreTokens()) {
    	        try {
    	          tokenizer = new StringTokenizer(reader.readLine());
    	        } catch (IOException e) {
    	          throw new RuntimeException(e);
    	        }
    	      }
    	      return tokenizer.nextToken();
    	    }
    		public long nextLong() {
    		      return Long.parseLong(next());
    		    }
    	    public int nextInt() {
    	      return Integer.parseInt(next());
    	    }
    	  }

}


import java.util.*;
public class A630 {
	public static void main(String[] args)
	{
		Scanner scan = new Scanner(System.in);
		long n = scan.nextLong();
		System.out.println(25);
	}
}


import java.io.PrintWriter;
import java.util.Scanner;

public class HexadecimalTheorem {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int n = in.nextInt();
		PrintWriter out = new PrintWriter(System.out);
		out.printf("%d %d %d%n", 0, 0, n);
		out.flush();
	}

}


/**
 * Created by IntelliJ IDEA.
 * User: SONY
 * Date: 27.05.12
 * Time: 18:25
 * To change this template use File | Settings | File Templates.
 */

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

public class TaskA extends Thread {
    public TaskA(String inputFileName, String outputFileName) {
        try {
            if (inputFileName != null) {
                this.input = new BufferedReader(new FileReader(inputFileName));
            } else {
                this.input = new BufferedReader(new InputStreamReader(System.in));
            }
            if (outputFileName != null) {
                this.output = new PrintWriter(outputFileName);
            } else {
                this.output = new PrintWriter(System.out);
            }
            this.setPriority(Thread.MAX_PRIORITY);
        } catch (Throwable e) {
            System.err.println(e.getMessage());
            e.printStackTrace();
            System.exit(666);
        }
    }

    private void solve() throws Throwable {
        long n = nextLong();
        output.println("0 0 " + n);
    }

    public void run() {
        try {
            solve();
        } catch (Throwable e) {
            System.err.println(e.getMessage());
            e.printStackTrace();
            System.exit(666);
        } finally {
            output.close();
        }
    }

    public static void main(String... args) {
        new TaskA(null, null).start();
    }

    private int nextInt() throws IOException {
        return Integer.parseInt(next());
    }

    private double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }

    private long nextLong() throws IOException {
        return Long.parseLong(next());
    }

    private String next() throws IOException {
        while (tokens == null || !tokens.hasMoreTokens()) {
            tokens = new StringTokenizer(input.readLine());
        }
        return tokens.nextToken();
    }

    private StringTokenizer tokens;
    private BufferedReader input;
    private PrintWriter output;
}


import java.io.File;
import java.io.FileNotFoundException;
import java.util.Scanner;

public class A {
    public static void main(String[] args) throws FileNotFoundException {
        Scanner s = new Scanner(System.in);
        int T = s.nextInt();
        System.out.println("0 0 "+T);
        /*if(T==0) {

            return;
        }
        if(T==1) {
            System.out.println("0 0 0");
            return;
        }
        System.out.println();*/
    }
}


import java.util.Scanner;

public class A{
	public static void main(String[] args){
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();

		int prev2=0;
		int prev1=1;
		int prev=1;
		int curr = 2;
		if(n == 0) {System.out.println("0 0 0"); return;}
		else if(n == 1) {System.out.println("0 0 1");return;}
		while(true){
			if(curr == n) break;
			prev2 = prev1;
			prev1 = prev;
			int temp = prev + curr;
			prev = curr;
			curr = temp;
		}
		System.out.println(prev2 + " " + prev1 + " " + prev1);
	}
}


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

public class CF125A {

	private void work() throws IOException {
		Scanner sc = new Scanner(new BufferedReader(new InputStreamReader(
				System.in)));
		int n = sc.nextInt();
		System.out.printf("%d %d %d\n", 0, 0, n);
		System.out.close();
	}

	public static void main(String[] args) throws IOException {
		new CF125A().work();
	}

}


import java.io.*;
import java.math.BigInteger;
import java.util.*;
import java.util.Map.Entry;

public class Main {
	public static void main(String[] args) throws IOException {
		(new Main()).solve();
	}

	public void Main() {
	}

	void solve() throws IOException {
		// BufferedReader in = new BufferedReader(new
		// InputStreamReader(System.in));
		// Scanner in = new Scanner(System.in);
		MyReader in = new MyReader();
		PrintWriter out = new PrintWriter(System.out);
		// Scanner in = new Scanner(new FileReader("input.txt"));
		// PrintWriter out = new PrintWriter("output.txt");

		int n = in.nextInt();
		out.print("0 0 ");
		out.print(n);

		out.close();
	}

};

class MyReader {
	private BufferedReader in;
	String[] parsed;
	int index = 0;

	public MyReader() {
		in = new BufferedReader(new InputStreamReader(System.in));
	}

	public int nextInt() throws NumberFormatException, IOException {
		if (parsed == null || parsed.length == index) {
			read();
		}
		return Integer.parseInt(parsed[index++]);
	}

	public long nextLong() throws NumberFormatException, IOException {
		if (parsed == null || parsed.length == index) {
			read();
		}
		return Long.parseLong(parsed[index++]);
	}

	public String nextString() throws IOException {
		if (parsed == null || parsed.length == index) {
			read();
		}
		return parsed[index++];
	}

	private void read() throws IOException {
		parsed = in.readLine().split(" ");
		index = 0;
	}

	public String readLine() throws IOException {
		return in.readLine();
	}
};


import java.util.Scanner;

public class CF125D2A {

    /**
     * @param args
     */
    public static void main(String[] args) {
        Scanner sc = new Scanner (System.in);
        System.out.println("0 0 "+ sc.nextInt());

    }

}


import java.util.Scanner;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author scawn
 */
public class Main {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner cin = new Scanner (System.in);
        int n = cin.nextInt();
        long res = 2;
        long[] a = new long[4];
        a[0] = 0;
        a[1] = 1;
        a[2] = 1;
        a[3] = 2;
        if (n == 1){
            System.out.println("0 0 1");
            return;
        }
        if (n == 2){
            System.out.println("0 1 1");
            return;
        }
        if (n == 0){
            System.out.println("0 0 0");
            return;
        }
//        if (n == 1 || n == 2 || n == 0){
//            System.out.println("I'm too stupid to solve this problem");
//            return;
//        }
        if (n == 3){
            System.out.println("1 1 1");
            return;
        }
        do{
            a[3] = res;
            res = a[2] + a[3];
            if (res == n){
                System.out.println (a[0] + " " + a[1] + " " + a[3]);
                return;
            }
            a[0] = a[1];
            a[1] = a[2];
            a[2] = a[3];

        }while (true);
    }
}


import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner r = new Scanner(System.in);

        int N = r.nextInt();

        System.out.println(N + " " + 0 + " " + 0);
    }
}


import java.util.*;

public class Main {
    final int INF = Integer.MAX_VALUE / 2;
    private void doit(){
        Scanner sc = new Scanner(System.in);
        //while(sc.hasNext()){
            int n = sc.nextInt();
            if(n == 0){
                System.out.println("0 0 0");
            }
            else if(n == 1){
                System.out.println("0 0 1");
            }
            else{
                //create a fib
                ArrayList<Integer> fibList = new ArrayList<Integer>();
                int pre = 0;
                int next = 1;
                fibList.add(pre);
                fibList.add(next);
                while(next != n){
                    int temp = next;
                    next +=pre;
                    fibList.add(next);
                    pre = temp;
                }
                int len = fibList.size();
                int a = fibList.get(len-4);
                int b = fibList.get(len-3);
                int c = fibList.get(len-3);
                System.out.println(a + " " + b + " " + c);
            }
        //}
    }

    public static void main(String[] args) {
        Main obj = new Main();
        obj.doit();
    }
}


/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
//package CodeForces3;

import java.util.ArrayList;
import java.util.Scanner;

/**
 *
 * @author DELL
 */
public class HexadecimalsTheorem {

    public void solve() {
        Scanner sc = new Scanner(System.in);
        long n = sc.nextLong();

        ArrayList<Long> a = new ArrayList<Long>();

        a.add(0l);
        a.add(1L);
        a.add(1L);

        int i = 1, j = 2;

        while ((a.get(i) + a.get(j)) <= n) {
            a.add((a.get(i) + a.get(j)));
            i++;
            j++;
        }

        if (a.contains(n)) {
            if (n == 0) {
                System.out.println("0 0 0");
            } else if (n == 1) {
                System.out.println("0 0 1");
            } else if (n == 2) {
                System.out.println("0 1 1");
            } else {
                System.out.println(a.get(j - 4) + " " + a.get(j - 3) + " " + a.get(j - 1));

            }

        } else {
            System.out.println("I'm too stupid to solve this problem");
        }

    }

    public static void main(String[] args) {
        new HexadecimalsTheorem().solve();
    }
}


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

public class Contest1_1{

    public static void main(String ar[]) throws Exception {

        BufferedReader buff = new BufferedReader(new InputStreamReader(System.in));
        int input = Integer.parseInt(buff.readLine());
        if(input==0){
            System.out.println("0 0 0");
        }else if(input==1){
            System.out.println("0 0 1");
        }else if(input==2){
            System.out.println("0 1 1");
        }else if(input==3){
            System.out.println("1 1 1");
        }else {
            int output[] = checkFibo(input);
            int get[] = checkFibo(output[1]);
            output[0] = get[1];
            output[1] = get[2];
            System.out.print(output[0]);
            System.out.print(" " + output[1]);
            System.out.println(" " + output[2]);
        }
    }

    public static int[] checkFibo(int input){
        int output[] = new int[3];
        int fibo_1 = 0;
        int fibo_2 = 1;
        int temp = 0;
        while(fibo_2!=input){
            temp = fibo_2;
            output[1] = fibo_1;
            output[2] = fibo_2;
            fibo_2 += fibo_1;
            fibo_1 = temp;
        }
        return output;
    }
}


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

public class Hexadecimaltheorem {
	public static void main(String[] args) {
		BufferedReader buf = new BufferedReader(
				new InputStreamReader(System.in));
		int x;
		ArrayList<Integer> arr = new ArrayList<Integer>();
		arr.add(0);
		arr.add(1);
		try {
			while ((x = Integer.parseInt(buf.readLine())) != -1) {
				if (x == 1) {

					System.out.println(arr.get(0) + " " + arr.get(0) + " "
							+ arr.get(1));
				} else if (x == 0) {
					System.out.println(arr.get(0) + " " + arr.get(0) + " "
							+ arr.get(0));
				} else {
					int i = 1;
					while (x > arr.get(arr.size() - 1)) {
						arr.add(arr.get(i) + arr.get(i - 1));
						i++;
					}
					System.out.println(arr.get(0) + " " + arr.get(i - 2) + " "
							+ arr.get(i - 1));
				}
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.Scanner;
import java.util.StringTokenizer;

public class CF125D2A {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("0 0 " + sc.nextInt());
    }
}


import java.util.Scanner;

public class ProblemA {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        long n = sc.nextLong();
        long[] answer = new long[3];
        if (n == 1) {
            answer[0] = 0;
            answer[1] = 0;
            answer[2] = 1;
        } else if (n > 1) {
            long f1 = 0;
            long f2 = 1;
            long m = 0;
            while (m < n) {
                answer[0] = answer[1];
                answer[1] = f1;
                answer[2] = f2;
                m = f1 + f2;
                f1 = f2;
                f2 = m;
            }
            answer[2] = answer[1];
        }
        System.out.println(answer[0] + " " + answer[1] + " " + answer[2]);
    }
}


import java.util.*;

public class A {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        System.out.println("0 0 " + n);
    }
}


import java.io.*;

import java.util.*;
import java.util.concurrent.ArrayBlockingQueue;

import javax.print.attribute.HashAttributeSet;

public class CodeForces {

	public void solve() throws IOException {
		int n = nextInt();
		int arr[]=new int[1000];
		arr[0]=0;
		arr[1]=1;
		arr[2]=1;
		if(n==0){
			out.print("0 0 0");
		}
		else if(n==1){
			out.print("0 0 1");
		} else {
			int c=2;
			while(arr[c]!=n){
				c++;
				arr[c]=arr[c-1]+arr[c-2];
			}
			out.print(arr[c-2]+" "+arr[c-2]+" "+arr[c-3]);
		}

	}

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

	int NOD(int a, int b) {
		while (a != 0 && b != 0) {
			if (a >= b)
				a = a % b;
			else
				b = b % a;
		}
		return a + b;
	}

	BufferedReader reader;
	StringTokenizer tokenizer;
	PrintWriter out;
	boolean isOuterFile = false;

	public void run() {
		try {
			if (isOuterFile) {
				reader = new BufferedReader(new FileReader("input.txt"));
				out = new PrintWriter(new BufferedWriter(new FileWriter("output.txt")));
				out = new PrintWriter(System.out);
			} else {
				reader = new BufferedReader(new InputStreamReader(System.in));
				out = new PrintWriter(System.out);
			}

			tokenizer = null;
			// long t=new Date().getTime();
			solve();
			// writer.println(t-new Date().getTime());
			reader.close();
			out.close();
		} catch (Exception e) {
			e.printStackTrace();
			System.exit(1);
		}
	}

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

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

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

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


import java.util.Scanner;

/**
 *
 * @author Gitesh
 */
public class JavaApplication2 {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);

                int n;
                      n=s.nextInt();
                      System.out.print(n+" "+"0 0");
}
}


import java.util.Scanner;

public class HexadecimalTheorem {
    public static void main(String[] args) {
        Scanner read = new Scanner(System.in);
        int num = read.nextInt();
        int zero, one, two, three;
        zero = 0;
        one = 1;
        two = 1;
        three = 2;
        if(num == 0)
            System.out.println("0 0 0");
        else if(num == 1)
            System.out.println("0 0 1");
        else{
            while(num != three){
                zero = one;
                one = two;
                two = three;
                three = three + one;
            }
            System.out.println(zero + " " + one + " " + one);
        }
    }
}


import java.util.Scanner;

public class Main {

    /**
     * @param args
     */
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int x = scan.nextInt();
    solve(x);

    }
    public static void solve (int x){
        int z = 0 ;
        System.out.print(z+" ");
        System.out.print(z+" ");
        System.out.print(x);

    }

}


import java.util.Scanner;

public class A {

    public static void main(String args[]) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int f1 = 0;
        int f2 = 1;
        int f3 = 1;
        while (f3 < n) {
            f1 = f2;
            f2 = f3;
            f3 = f1 + f2;
        }
        if (n == 0) {
            System.out.println(0 + " " + 0 + " " + 0);
        } else if (f3 == n) {
            System.out.println(f1 + " " + f1 + " " + (f2 - f1));
        } else {
            System.out.println("I'm too stupid to solve this problem");
        }
    }
}


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

/**
 * Author: Maksim Novik
 * Date: 30.06.12
 * Time: 22:34
 */
public class Round125ProblemA {

    public static void main(String[] args) {
        InputStream in = System.in;
        OutputStream out = System.out;
        InputReader reader = new InputReader(in);
        PrintWriter writer = new PrintWriter(out);
        solve(reader, writer);
        writer.close();
    }

    static void solve(InputReader in, PrintWriter out) {
        long fib = in.nextLong();
        out.write("" + 0  + " " + 0 + " " + fib);
    }

    static class InputReader {
        private BufferedReader reader;
        private StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream));
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

    }
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class Solver {

    StringTokenizer st;
    BufferedReader in;
    PrintWriter out;

    public static void main(String[] args) throws NumberFormatException, IOException {
        Solver solver = new Solver();
        solver.open();
        solver.solve();
        solver.close();
    }

    public void open() throws IOException {
        in = new BufferedReader(new InputStreamReader(System.in));
        out = new PrintWriter(System.out);
    }

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

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

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

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

    public void solve() throws NumberFormatException, IOException {
        int n = nextInt();
        out.println(0+" "+0+" "+n);
    }

    public void close() {
        out.flush();
        out.close();
    }

}


import java.io.PrintWriter;
import java.util.Arrays;
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {

        Scanner in = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        int n = in.nextInt();

        out.println(n+" 0 0");

        in.close();
        out.close();

    }

}


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

public class program{
	public static void main(String args[]) throws Exception{
		Scanner sc=new Scanner(System.in);
		int n=sc.nextInt();
		if(n==0){
			System.out.println("0 0 0");
			return;
		}
		else if(n==1){
			System.out.println("0 0 1");
			return;
		}
		else if(n==2){
			System.out.println("0 1 1");
			return;
		}
		else{
			int ppp=0;
			int pp=1;
			int c=2;
			while(true){
				if(ppp+pp+c==n){
					System.out.println(ppp+" "+pp+" "+c);
					return;
				}
				else{
					c=c+pp+ppp;
					int temp=pp;
					pp=pp+ppp;
					ppp=temp;
				}
			}
		}
	}
}


import java.util.LinkedList;
import java.util.Scanner;

public class HexadecimalsTheorem {

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int num = in.nextInt();
        LinkedList<Integer> result = new LinkedList<Integer>();
        int temp0 = 1;
        int temp1 = 1;
        int temp2 = 0;
        result.add(0);
        result.add(0);
        result.add(0);
        result.add(temp0);
        result.add(temp1);
        if (num == 2) {
            System.out.println(0 + " " + 1 + " " + 1);
        } else if (num == 0) {
            System.out.println(0 + " " + 0 + " " + 0);
        } else {
            while (temp2 < num) {
                temp2 = temp1 + temp0;
                result.add(temp2);
                temp0 = temp1;
                temp1 = temp2;
            }
            int length = result.size();
            System.out.println(result.get(length - 5) + " "
                    + result.get(length - 4) + " " + result.get(length - 2));
        }
    }

}


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

public class A {
	static Scanner scan = new Scanner (System.in);
	static PrintStream out = System.out;

	static void go (int n) {
		if (n == 0) {
			System.out.println (0 + " " + 0 + " " + 0);
			return;
		}
		int a = 0, b = 1;
		int c = a + b;
		while (n > c) {
			a = b;
			b = c;
			c = a + b;
		}
		System.out.println (0 + " " + a + " " + b);
	}

	public static void main (String[] args) {
		int n = scan.nextInt();
		go (n);

	}

}


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

public class Main {
	static Scanner scan = new Scanner (System.in);
	static PrintStream out = System.out;

	static int n;
	static void solve () {
		System.out.println (0 + " " + 0 + " " + n);
	}

	public static void main (String[] args) {
		n = scan.nextInt();
		solve ();
	}
}


import java.io.*;
import java.util.*;
public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        List<Integer> fibs = new ArrayList<Integer>();
        int fib0 = 0;
        int fib1 = 1;
        int fibN = fib0+fib1;
        fibs.add(fib0);
        fibs.add(fib1);
        while(fibN < 1000000000){
            fibs.add(fibN);
            fib0 = fib1;
            fib1 = fibN;
            fibN = fib0+fib1;
        }
        int n = Integer.parseInt(br.readLine());

        if(n == 0){System.out.println(0+" "+0+" "+0);}
        else{
            if(n == 1){System.out.println(0+" "+0+" "+1);}
            else{
                if(n == 2){System.out.println(0+" "+1+" "+1);}
                else{
        int i = fibs.indexOf(n);
        System.out.println(fibs.get(i-4)+" "+fibs.get(i-3)+" "+fibs.get(i-1));
    }}
        }
}
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class A125D2 {

	public static void main(String[] args) throws Exception {
		InputReader in = new InputReader(System.in);
		System.out.println(0 + " " + 0 + " " + in.nextInt());
	}

	static class InputReader {
		private BufferedReader reader;
		private StringTokenizer tokenizer;

		public InputReader(InputStream stream) {
			reader = new BufferedReader(new InputStreamReader(stream));
			tokenizer = null;
		}

		public String next() {
			while (tokenizer == null || !tokenizer.hasMoreTokens()) {
				try {
					tokenizer = new StringTokenizer(reader.readLine());
				} catch (IOException e) {
					throw new RuntimeException(e);
				}
			}
			return tokenizer.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}
	}
}


/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

import java.util.Scanner;

/**
 *
 * @author dilshan
 */
public class Test {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int n = s.nextInt();
        int k = 1;
        int t = 0;
        int y = 2;
        int[] a = new int[100000];
        if(n==0){
            System.out.println(0+" "+0+" "+0);
        }
        else
            if(n==1){
            System.out.println(0+" "+0+" "+1);
            }
            else
                if(n==2){
                System.out.println(0+" "+1+" "+1);
                }
                else{
                    a[0] = 0;
                    a[1] = 1;
                    a[y] = a[y - 2] + a[y - 1];
                    while (a[y - 1] < n) {

                        a[y] = a[y - 2] + a[y - 1];
                        ++y;

                    }
                    System.out.println(a[y - 2] + " " + a[y - 4] + " " + a[y - 5]);
            }
        //System.out.println(y);

    }
}


import java.util.*;
public class Hexadecimal {
 public static void main(String args[]){
	 Scanner input = new Scanner(System.in);
	 int n = input.nextInt();
	 System.out.print("0 0 " + n);
 }
}


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

public class Main {
public static void main(String args[]) throws Exception
    {

     BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
     int n=Integer.parseInt(br.readLine());
     System.out.println("0 0 "+n);}

}


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

public class C125 {
	public static void main(String[] args) throws IOException {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		String s = r.readLine();
		int n = new Integer(s);
		System.out.println("0 0 "+n);
	}
}


import java.io.InputStreamReader;
import java.util.Scanner;

public class Hexadecimal {

    public static void main(String [] args){
        Scanner s = new Scanner(new InputStreamReader(System.in));

        int x = s.nextInt();

       System.out.println(x + " " + 0 + " " + 0);
    }
}


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

public class A {
    public static void main(String[] args) throws Exception {
        new A().solve();
    }
    void solve() throws IOException {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(in.readLine());
        if (n == 0) {
            System.out.println("0 0 0");
            return;
        }
        int p2 = 0;
        int p1 = 1;
        while (true) {
            int now = p2 + p1;
            if (n == now) {
                System.out.println("0 " + p1 + " " + p2);
                return;
            } else {
                p2 = p1;
                p1 = now;
            }
        }
    }
}


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

public class HexTheorem {
    public static void main(String[] args) throws NumberFormatException, IOException {
        BufferedReader read = new BufferedReader(new InputStreamReader(System.in));
        int x = Integer.parseInt(read.readLine());
        System.out.println("0 0 "+x);
    }
}


import java.io.*;
import java.text.*;
import java.math.*;
import java.util.*;

public class Hexadec implements Runnable {

    final static String taskname = "filename";

    public void solve() throws Exception {
    //	int n = iread();
    	int n = Integer.parseInt(in.readLine());

    	out.write(n + " "+0+" "+0);
    //    out.write(ans_path + "\n");
    }

    public void run() {
        try {
            in = new BufferedReader(new InputStreamReader(System.in));
            out = new BufferedWriter(new OutputStreamWriter(System.out));
//             in = new BufferedReader(new FileReader(taskname + ".in"));
//             out = new BufferedWriter(new FileWriter(taskname + ".out"));
            solve();
            out.flush();
        } catch (Exception e) {
            e.printStackTrace();
            System.exit(1);
        }
    }

    public int iread() throws Exception {
        return Integer.parseInt(readword());
    }

    public double dread() throws Exception {
        return Double.parseDouble(readword());
    }

    public long lread() throws Exception {
        return Long.parseLong(readword());
    }

    BufferedReader in;

    BufferedWriter out;

    public String readword() throws IOException {
        StringBuilder b = new StringBuilder();
        int c;
        c = in.read();
        while (c >= 0 && c <= ' ')
            c = in.read();
        if (c < 0)
            return "";
        while (c > ' ') {
            b.append((char) c);
            c = in.read();
        }
        return b.toString();
    }

    public static void main(String[] args) {
        // Locale.setDefault(Locale.US);
        new Thread(new Hexadec()).start();
    }
}


import java.util.Scanner;
public class Fibonacci {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		long num =0;
		num = input.nextLong();
		while (num<0 || num>Math.pow(10,9))
		{
			System.out.println("Invalid");
			num = input.nextLong();
		}
		System.out.println("0 0 "+num);
	}
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;
import java.util.StringTokenizer;

public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskA solver = new TaskA();
        solver.solve(in, out);
        out.close();
    }
}

class TaskA {
    int n;
    int m;
    String answer = "I'm too stupid to solve this problem";
    public void solve(InputReader in, PrintWriter out) {
        n = in.nextInt();
        out.println("0 0 " + n);
    }

}

class InputReader {
    private BufferedReader reader;
    private StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream));
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
}


import java.util.Scanner;

public class N1_CF_199A {
    public static void main(String[] args) {
    int n = new Scanner(System.in).nextInt();
    if( n == 0)
    {
        System.out.println(0);
        System.out.println(0);
        System.out.println(0);
        return;
    }
    int i = 0 , j = 1;
    while(true)
    {
        int t = i + j;
        if( t == n)
        break;
        i = j;
        j = t;
    }
    System.out.println(i);
    System.out.println(j);
    System.out.println(0);
    }
}


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

public class a extends Thread {

	BufferedReader bf;
	PrintWriter out;
	FastScanner in;

	void solve() throws Exception {
		long n = in.nextLong();
		long f[] = new long[2001];
		int i = 2;
		f[0] = 0;
		f[1] = 1;
		while (true){
			f[i] = f[i-1] + f[i-2];
			if (f[i] < n) i++;
			else break;
		}
		if (n == 1) out.println("1 0 0");
		else if (n == 0) out.println("0 0 0");
		else
		if (i - 3 >= 0) out.println(f[i-2] +" " + f[i-2] + " " +f[i-3]);
		else out.println("I'm too stupid to solve this problem");
	}

	public void run() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			out = new PrintWriter(System.out);
			in = new FastScanner(bf);
			solve();
			out.flush();
		} catch (Exception ex) {
			ex.printStackTrace();
		} finally {
			out.close();
		}
	}

	public static void main(String args[]) {
		new a().start();
	}

	class FastScanner {
		BufferedReader bf;
		StringTokenizer st;

		public FastScanner(BufferedReader bf) {
			this.bf = bf;
		}

		public String nextToken() throws Exception {
			while (st == null || !st.hasMoreTokens()) {
				st = new StringTokenizer(bf.readLine());
			}
			return st.nextToken();
		}

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

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

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

		public BigInteger nextBigInteger() throws Exception {
			return new BigInteger(nextToken());
		}
	}
}


import java.util.*;

public class A {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();

        List<Long> fi = new ArrayList<Long>();

        fi.add((long) 0);
        fi.add((long) 1);

        while (fi.get(fi.size()-1)<n) {
            fi.add(fi.get(fi.size()-1)+fi.get(fi.size()-2));
        }

        int last = fi.size()-1;

        long z = last-1>=0 ? fi.get(last-1) : 0;
        long y = last-3>=0 ? fi.get(last-3) : 0;
        long x = last-4>=0 ? fi.get(last-4) : 0;

        if (x+y+z<n)
            x=1;

        System.out.println(x+" "+y+" "+z);
    }

}


import static java.lang.Math.*;
import static java.util.Arrays.*;
import static java.util.Collections.*;
import java.io.*;
import java.math.*;
import java.util.*;

@SuppressWarnings("unused")
public class A {
	public static void main(String[] args) throws Exception {
		Scanner in = new Scanner(System.in);
		long n = in.nextLong();
		System.out.println("0 0 " + n);
	}
}


import java.io.IOException;
import java.util.Scanner;

public class A199 {
	static int n[][] = new int[][] { { -1, 0 }, { 1, 0 }, { 0, -1 }, { 0, 1 } };

	public static void main(String[] args) throws IOException {
		new A199().solve();
	}

	public void solve() throws IOException {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
//		int f1 = 0;
//		int f2 = 1;
//
//		while(true){
//			int t = f1 + f2;
//			if(t == N){
//				//guaranteed that n is a Fibonacci number
//				break;
//			}
//			f1 = f2;
//			f2 = t;
//		}
		System.out.println("0 0 " + N );
	}
}


import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * User: vaibhav mittal
 * Date: 23/6/12
 * Time: 1:15 AM
 * To change this template use File | Settings | File Templates.
 */
public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        long n = in.nextLong();
        out.println(0 + " " + 0 + " " + n);

        in.close();
        out.close();
    }
}


import java.util.*;
import java.io.*;
import java.text.*;
import java.math.*;
import static java.lang.Integer.*;
import static java.lang.Double.*;
import java.lang.Math.*;

public class two_squares {

	public static void main(String[] args) throws Exception {
		new two_squares().run();
	}

	public void run() throws Exception {
		FastIO file = new FastIO();
		double x1 = file.nextInt();
		double y1 = file.nextInt();
		double x2 = file.nextInt();
		double y2 = file.nextInt();
		double x3 = file.nextInt();
		double y3 = file.nextInt();
		double x4 = file.nextInt();
		double y4 = file.nextInt();
		double minx1, maxx1, miny1, maxy1;
		minx1 = Math.min(x1, Math.min(x2, Math.min(x3, x4)));
		maxx1 = Math.max(x1, Math.max(x2, Math.max(x3, x4)));
		miny1 = Math.min(y1, Math.min(y2, Math.min(y3, y4)));
		maxy1 = Math.max(y1, Math.max(y2, Math.max(y3, y4)));
		double x5 = file.nextInt();
		double y5 = file.nextInt();
		double x6 = file.nextInt();
		double y6 = file.nextInt();
		double x7 = file.nextInt();
		double y7 = file.nextInt();
		double x8 = file.nextInt();
		double y8 = file.nextInt();
		double minx2, maxx2, miny2, maxy2;
		minx2 = Math.min(x5, Math.min(x6, Math.min(x7, x8)));
		maxx2 = Math.max(x5, Math.max(x6, Math.max(x7, x8)));
		miny2 = Math.min(y5, Math.min(y6, Math.min(y7, y8)));
		maxy2 = Math.max(y5, Math.max(y6, Math.max(y7, y8)));
		Point _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16;
		_1 = new Point(x1, y1);
		_2 = new Point(x2, y2);
		_3 = new Point(x3, y3);
		_4 = new Point(x4, y4);
		_5 = new Point(x5, y5);
		_6 = new Point(x6, y6);
		_7 = new Point(x7, y7);
		_8 = new Point(x8, y8);
		_9 = new Point(minx1, maxy1);
		_10 = new Point(minx1, miny1);
		_11 = new Point(maxx1, maxy1);
		_12 = new Point(maxx1, miny1);
		double m1 = (minx2 + maxx2) / 2;
		double m2 = (miny2 + maxy2) / 2;
		_13 = new Point(minx2, m2);
		_14 = new Point(m1, miny2);
		_15 = new Point(maxx2, m2);
		_16 = new Point(m1, maxy2);
		Point[] a = {_1, _2, _3, _4};
		Point[] b = {_5, _6, _7, _8};
		boolean works = false;
		Line[] aa = {new Line(_9,_10), new Line(_10, _12), new Line(_12, _11), new Line(_11, _9)};
		Line[] bb = {new Line(_13, _14), new Line(_14, _15), new Line(_15, _16), new Line(_16, _13)};
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 4; j++) {
				if (aa[i].intersection(bb[i]) != null) {
					works = true;
				}
			}
		}
		for (Point p : b) {
			if (p.x >= minx1 && p.x <= maxx1 && p.y >= miny1 && p.y <= maxy1) {
				works = true;
			}
		}
		for (Point p : a) {
			boolean result = false;
		      for (int i = 0, j = b.length - 1; i < b.length; j = i++) {
		        if ((b[i].y > p.y) != (b[j].y > p.y) &&
		            (p.x < (b[j].x - b[i].x) * (p.y - b[i].y) / (b[j].y-b[i].y) + b[i].x)) {
		          result = !result;
		         }
		      }
		      if (result) works = true;
		}
		System.out.println(works ? "YES" : "NO");
	}
	public static class Point {
		double x, y;
		public Point(double a, double b) {
			x = a;
			y = b;
		}
	}
	public static class Line {
		Point a, b;
		public Line(Point x, Point y) {
			a = x;
			b = y;
		}
		public Point intersection(Line o) {
			double x1 = a.x;
			double y1 = a.y;
			double x2 = b.x;
			double y2 = b.y;
			double x3 = o.a.x;
			double y3 = o.a.y;
			double x4 = o.b.x;
			double y4 = o.b.y;
			double denom = (y4 - y3) * (x2 - x1) - (x4 - x3) * (y2 - y1);
			  double ua = ((x4 - x3) * (y1 - y3) - (y4 - y3) * (x1 - x3))/denom;
			  double ub = ((x2 - x1) * (y1 - y3) - (y2 - y1) * (x1 - x3))/denom;
			    if (ua >= 0.0f && ua <= 1.0f && ub >= 0.0f && ub <= 1.0f) {
			        return new Point((int) (x1 + ua*(x2 - x1)), (int) (y1 + ua*(y2 - y1)));
			    }

			  return null;
		}
	}
	public static class FastIO {
		BufferedReader br;
		StringTokenizer st;

		public FastIO() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		String next() {
			while (st == null || !st.hasMoreElements()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

		int nextInt() {
			return Integer.parseInt(next());
		}

		long nextLong() {
			return Long.parseLong(next());
		}

		double nextDouble() {
			return Double.parseDouble(next());
		}

		String nextLine() {
			String str = "";
			try {
				str = br.readLine();
			} catch (IOException e) {
				e.printStackTrace();
			}
			return str;
		}
	}

	public static long pow(long n, long p, long mod) {
		if (p == 0)
			return 1;
		if (p == 1)
			return n % mod;
		if (p % 2 == 0) {
			long temp = pow(n, p / 2, mod);
			return (temp * temp) % mod;
		} else {
			long temp = pow(n, p / 2, mod);
			temp = (temp * temp) % mod;
			return (temp * n) % mod;

		}
	}

	public static long pow(long n, long p) {
		if (p == 0)
			return 1;
		if (p == 1)
			return n;
		if (p % 2 == 0) {
			long temp = pow(n, p / 2);
			return (temp * temp);
		} else {
			long temp = pow(n, p / 2);
			temp = (temp * temp);
			return (temp * n);

		}
	}

	public static long gcd(long x, long y) {
		if (x == 0)
			return y;
		else
			return gcd(y % x, x);
	}

	public static boolean isPrime(int n) {
		if (n <= 1)
			return false;
		if (n <= 3)
			return true;

		if (n % 2 == 0 || n % 3 == 0)
			return false;

		for (int i = 5; i * i <= n; i = i + 6)
			if (n % i == 0 || n % (i + 2) == 0)
				return false;

		return true;
	}
}


import java.awt.Point;
import java.io.*;
import java.math.BigInteger;
import java.util.*;

public class C {

	static StringBuilder st = new StringBuilder();

		public static void main(String[] args) throws Exception {
		Scanner sc = new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out);

		Point [] square = new Point [4] ;
		Point [] rotSquare = new Point[4] ;

		for(int i = 0 ; i < 4 ;i++)
			square[i] = new Point(sc.nextInt() , sc.nextInt());

		for(int i = 0 ; i < 4 ;i++)
			rotSquare[i] = new Point(sc.nextInt() , sc.nextInt());

		boolean can = false ;

		for(int x = -100 ; x <= 100 ; x++)
			for(int y = -100 ; y <= 100 ; y++)
				can |= inside(new Point(x , y), square) & inside(new Point (x , y), rotSquare);

		out.println(can ? "YES" : "NO");

		out.flush();
		out.close();

	}
	static int crossProduct(Point a , Point b)
	{
		int ans = a.x * b.y - a.y * b.x ;

		if(ans < 0)return -1 ;
		if(ans == 0) return 0 ;
		return 1 ;
	}

	static boolean inside(Point a , Point [] points)
	{
		boolean allPos = true ;
		boolean allNeg = true ;

		for(int i = 0 ; i < 4 ; i++)
		{
			Point v1 = new Point (points[i].x - a.x , points[i].y - a.y) ;
			Point v2 = new Point (points[(i + 1) % 4].x - a.x , points[(i + 1) % 4].y - a.y) ;

			allPos &= crossProduct(v1, v2) >= 0;
			allNeg &= crossProduct(v1, v2) <= 0;
		}
		return allPos | allNeg ;

	}

	static class Scanner {
		BufferedReader br;
		StringTokenizer st;

		Scanner(InputStream in) {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		String next() throws Exception {
			while (st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());

			return st.nextToken();
		}

		int nextInt() throws Exception {
			return Integer.parseInt(next());
		}

		long nextLong() throws Exception {
			return Long.parseLong(next());
		}

		double nextDouble() throws Exception {
			return Double.parseDouble(next());
		}

	}

	static void shuffle(int[] a) {
		int n = a.length;
		for (int i = 0; i < n; i++) {
			int r = i + (int) (Math.random() * (n - i));
			int tmp = a[i];
			a[i] = a[r];
			a[r] = tmp;
		}
	}

}


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

public class C994{
	static double area(double x1,double y1,double x2,double y2,double x3,double y3){
		return Math.abs((x1 * (y2 - y3) +
        x2 * (y3 - y1) + x3 * (y1 - y2)) / 2.0);
	}
	public static void main(String args[])throws IOException{
		Scanner sc=new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		PrintWriter pw=new PrintWriter(System.out);
		int x11=sc.nextInt();
		int y11=sc.nextInt();
		int x12=sc.nextInt();
		int y12=sc.nextInt();
		int x13=sc.nextInt();
		int y13=sc.nextInt();
		int x14=sc.nextInt();
		int y14=sc.nextInt();
		double x1c=(x11+x12+x13+x14)/4.0;
		double y1c=(y11+y12+y13+y14)/4.0;
		int x21=sc.nextInt();
		int y21=sc.nextInt();
		int x22=sc.nextInt();
		int y22=sc.nextInt();
		int x23=sc.nextInt();
		int y23=sc.nextInt();
		int x24=sc.nextInt();
		int y24=sc.nextInt();
		double x2c=(x21+x22+x23+x24)/4.0;
		double y2c=(y21+y22+y23+y24)/4.0;
		double a1=area(x11,y11,x12,y12,x13,y13)+area(x11,y11,x13,y13,x14,y14);
		double a2=area(x21,y21,x22,y22,x23,y23)+area(x21,y21,x23,y23,x24,y24);
		if(a1==area(x11,y11,x12,y12,x21,y21)+area(x11,y11,x21,y21,x14,y14)+area(x21,y21,x12,y12,x13,y13)+area(x21,y21,x14,y14,x13,y13)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a1==area(x11,y11,x12,y12,x22,y22)+area(x11,y11,x22,y22,x14,y14)+area(x22,y22,x12,y12,x13,y13)+area(x22,y22,x14,y14,x13,y13)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a1==area(x11,y11,x12,y12,x23,y23)+area(x11,y11,x23,y23,x14,y14)+area(x23,y23,x12,y12,x13,y13)+area(x23,y23,x14,y14,x13,y13)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a1==area(x11,y11,x12,y12,x24,y24)+area(x11,y11,x24,y24,x14,y14)+area(x24,y24,x12,y12,x13,y13)+area(x24,y24,x14,y14,x13,y13)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a1==area(x11,y11,x12,y12,x2c,y2c)+area(x11,y11,x2c,y2c,x14,y14)+area(x2c,y2c,x12,y12,x13,y13)+area(x2c,y2c,x14,y14,x13,y13)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a2==area(x21,y21,x22,y22,x11,y11)+area(x21,y21,x11,y11,x24,y24)+area(x11,y11,x22,y22,x23,y23)+area(x11,y11,x24,y24,x23,y23)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a2==area(x21,y21,x22,y22,x12,y12)+area(x21,y21,x12,y12,x24,y24)+area(x12,y12,x22,y22,x23,y23)+area(x12,y12,x24,y24,x23,y23)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a2==area(x21,y21,x22,y22,x13,y13)+area(x21,y21,x13,y13,x24,y24)+area(x13,y13,x22,y22,x23,y23)+area(x13,y13,x24,y24,x23,y23)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a2==area(x21,y21,x22,y22,x14,y14)+area(x21,y21,x14,y14,x24,y24)+area(x14,y14,x22,y22,x23,y23)+area(x14,y14,x24,y24,x23,y23)){
			pw.println("YES");
			pw.close();
			return;
		}
		if(a2==area(x21,y21,x22,y22,x1c,y1c)+area(x21,y21,x14,y14,x2c,y2c)+area(x1c,y1c,x22,y22,x23,y23)+area(x1c,y1c,x24,y24,x23,y23)){
			pw.println("YES");
			pw.close();
			return;
		}

		pw.println("NO");
		pw.close();
	}
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

/**
 * @author Don Li
 */
public class TwoSquares {

    int INF = 1000;

    void solve() {
        int[][] s1 = new int[4][2];
        for (int i = 0; i < 4; i++) {
            s1[i][0] = in.nextInt();
            s1[i][1] = in.nextInt();
        }

        int[][] s2 = new int[4][2];
        for (int i = 0; i < 4; i++) {
            s2[i][0] = in.nextInt();
            s2[i][1] = in.nextInt();
        }

        if (ok(s1, s2)) {
            out.println("Yes");
            return;
        }

        rotate(s1);
        rotate(s2);

        if (ok(s2, s1)) {
            out.println("Yes");
            return;
        }

        out.println("No");
    }

    void rotate(int[][] s) {
        for (int i = 0; i < 4; i++) {
            int x = s[i][0], y = s[i][1];
            s[i][0] = x - y;
            s[i][1] = x + y;
        }
    }

    boolean ok(int[][] s1, int[][] s2) {
        int xmin = INF, xmax = -INF, ymin = INF, ymax = -INF;
        for (int i = 0; i < 4; i++) {
            xmin = Math.min(xmin, s1[i][0]);
            xmax = Math.max(xmax, s1[i][0]);
            ymin = Math.min(ymin, s1[i][1]);
            ymax = Math.max(ymax, s1[i][1]);
        }

        for (int i = 0; i < 4; i++) {
            if (s2[i][0] >= xmin && s2[i][0] <= xmax && s2[i][1] >= ymin && s2[i][1] <= ymax) return true;
        }

        int[] mid2 = new int[]{s2[0][0] + s2[2][0], s2[0][1] + s2[2][1]};
        return mid2[0] >= xmin * 2 && mid2[0] <= xmax * 2 && mid2[1] >= ymin * 2 && mid2[1] <= ymax * 2;
    }

    public static void main(String[] args) {
        in = new FastScanner(new BufferedReader(new InputStreamReader(System.in)));
        out = new PrintWriter(System.out);
        new TwoSquares().solve();
        out.close();
    }

    static FastScanner in;
    static PrintWriter out;

    static class FastScanner {
        BufferedReader in;
        StringTokenizer st;

        public FastScanner(BufferedReader in) {
            this.in = in;
        }

        public String nextToken() {
            while (st == null || !st.hasMoreTokens()) {
                try {
                    st = new StringTokenizer(in.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

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

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

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


import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class cf2 {
	static final double EPS = 1e-9;

  public static void main(String[] args) throws IOException {
	 Scanner sc = new Scanner(System.in);

	 //rec
	 int xr1=sc.nextInt(), yr1=sc.nextInt(), xr2=sc.nextInt(),yr2=sc.nextInt();
	 int xr3=sc.nextInt(), yr3=sc.nextInt(), xr4=sc.nextInt(),yr4=sc.nextInt();

	 Point pr1 = new Point(xr1, yr1);
	 Point pr2 = new Point(xr2, yr2);
	 Point pr3 = new Point(xr3, yr3);
	 Point pr4 = new Point(xr4, yr4);

	 LineSegment lr1 = new LineSegment(pr1, pr2);
	 LineSegment lr2 = new LineSegment(pr2, pr3);
	 LineSegment lr3 = new LineSegment(pr3, pr4);
	 LineSegment lr4 = new LineSegment(pr4, pr1);

	 //diamond
	 int xd1=sc.nextInt(), yd1=sc.nextInt(), xd2=sc.nextInt(),yd2=sc.nextInt();
	 int xd3=sc.nextInt(), yd3=sc.nextInt(), xd4=sc.nextInt(),yd4=sc.nextInt();

	 Point p1 = new Point(xd1, yd1);
	 Point p2 = new Point(xd2, yd2);
	 Point p3 = new Point(xd3, yd3);
	 Point p4 = new Point(xd4, yd4);

	 Point [] pt = new Point [5];
	 pt[0]=p1;  pt[1]=p2;  pt[2]=p3;  pt[3]=p4;  pt[4]=p1;
	 Polygon pg = new Polygon(pt);

	 if(pg.inside(pr1)||pg.inside(pr2)||pg.inside(pr3)||pg.inside(pr4)) {
		 System.out.println("YES");
		 return;
	 }

	 LineSegment ld1 = new LineSegment(p1, p2);
	 LineSegment ld2 = new LineSegment(p2, p3);
	 LineSegment ld3 = new LineSegment(p3, p4);
	 LineSegment ld4 = new LineSegment(p4, p1);

	 Rectangle rec = new Rectangle(new Point(Math.min(Math.min(xr3,xr4),Math.min(xr1,xr2)), Math.min(Math.min(yr3,yr4),Math.min(yr1,yr2))),
			 new Point(Math.max(Math.max(xr3,xr4),Math.max(xr1,xr2)), Math.max(Math.max(yr3,yr4),Math.max(yr1,yr2))) );

	 if(rec.contains(p1)||rec.contains(p2)||rec.contains(p3)||rec.contains(p4)) {
		 System.out.println("YES");
	     return;
	 }

	 if(ld1.intersect(lr1)||ld1.intersect(lr3)||ld1.intersect(lr3)||ld1.intersect(lr4)) {
		 System.out.println("YES");
	     return;
	 }

	 if(ld2.intersect(lr1)||ld2.intersect(lr3)||ld2.intersect(lr3)||ld2.intersect(lr4)) {
		 System.out.println("YES");
	     return;
	 }

	 if(ld3.intersect(lr1)||ld3.intersect(lr3)||ld3.intersect(lr3)||ld3.intersect(lr4)) {
		 System.out.println("YES");
	     return;
	 }

	 if(ld4.intersect(lr1)||ld4.intersect(lr3)||ld4.intersect(lr3)||ld4.intersect(lr4)) {
		 System.out.println("YES");
	     return;
	 }

	 System.out.println("NO");

}

  public static class Polygon {
		// Cases to handle: collinear points, polygons with n < 3

		static final double EPS = 1e-9;

		Point[] g; 			//first point = last point, counter-clockwise representation

		Polygon(Point[] o) { g = o; }

		double perimeter()
		{
			double sum = 0.0;
			for(int i = 0; i < g.length - 1; ++i)
				sum += g[i].dist(g[i+1]);
			return sum;
		}

		double area() 		//clockwise/anti-clockwise check, for convex/concave polygons
		{
			double area = 0.0;
			for(int i = 0; i < g.length - 1; ++i)
				area += g[i].x * g[i+1].y - g[i].y * g[i+1].x;
			return Math.abs(area) / 2.0;			//negative value in case of clockwise
		}

		boolean inside(Point p)	//for convex/concave polygons - winding number algorithm
		{
			double sum = 0.0;
			for(int i = 0; i < g.length - 1; ++i)
			{
				double angle = Point.angle(g[i], p, g[i+1]);
				if((Math.abs(angle) < EPS || Math.abs(angle - Math.PI) < EPS) && p.between(g[i], g[i+1]))
					return true;
				if(Point.ccw(p, g[i], g[i+1]))
					sum += angle;
				else
					sum -= angle;
			}

			return Math.abs(2 * Math.PI - Math.abs(sum)) < EPS;		//abs makes it work for clockwise
		}
		/*
		 * Another way if the polygon is convex
		 * 1. Triangulate the poylgon through p
		 * 2. Check if sum areas == poygon area
		 * 3. Handle empty polygon
		 */

		Point centroid()		//center of mass
		{
			double cx = 0.0, cy = 0.0;
			for(int i = 0; i < g.length - 1; i++)
			{
				double x1 = g[i].x, y1 = g[i].y;
				double x2 = g[i+1].x, y2 = g[i+1].y;

				double f = x1 * y2 - x2 * y1;
				cx += (x1 + x2) * f;
				cy += (y1 + y2) * f;
			}
			double area = area();		//remove abs
			cx /= 6.0 * area;
			cy /= 6.0 * area;
			return new Point(cx, cy);
		}
	}

   static class LineSegment {

		Point p, q;

		LineSegment(Point a, Point b) { p = a; q = b; }

		boolean intersect(LineSegment ls)
		{
			Line l1 = new Line(p, q), l2 = new Line(ls.p, ls.q);
			if(l1.parallel(l2))
			{
				if(l1.same(l2))
					return p.between(ls.p, ls.q) || q.between(ls.p, ls.q) || ls.p.between(p, q) || ls.q.between(p, q);
				return false;
			}
			Point c = l1.intersect(l2);
			return c.between(p, q) && c.between(ls.p, ls.q);
		}

	}

   static class Rectangle {

		static final double EPS = 1e-9;

		Point ll, ur;

		Rectangle(Point a, Point b) { ll = a; ur = b; }

		double area() { return (ur.x - ll.x) * (ur.y - ll.y); }

		boolean contains(Point p)
		{
			return p.x <= ur.x + EPS && p.x + EPS >= ll.x && p.y <= ur.y + EPS && p.y + EPS >= ll.y;
		}

		Rectangle intersect(Rectangle r)
		{
			Point ll = new Point(Math.max(this.ll.x, r.ll.x), Math.max(this.ll.y, r.ll.y));
			Point ur = new Point(Math.min(this.ur.x, r.ur.x), Math.min(this.ur.y, r.ur.y));
			if(Math.abs(ur.x - ll.x) > EPS && Math.abs(ur.y - ll.y) > EPS && this.contains(ll) && this.contains(ur) && r.contains(ll) && r.contains(ur))
				return new Rectangle(ll, ur);
			return null;
		}

	}
   static class Line {

		static final double INF = 1e9, EPS = 1e-9;

		double a, b, c;

		Line(Point p, Point q)
		{
			if(Math.abs(p.x - q.x) < EPS) {	a = 1; b = 0; c = -p.x;	}
			else
			{
				a = (p.y - q.y) / (q.x - p.x);
				b = 1.0;
				c = -(a * p.x + p.y);
			}

		}

		Line(Point p, double m) { a = -m; b = 1; c =  -(a * p.x + p.y); }

		boolean parallel(Line l) { return Math.abs(a - l.a) < EPS && Math.abs(b - l.b) < EPS; }

		boolean same(Line l) { return parallel(l) && Math.abs(c - l.c) < EPS; }

		Point intersect(Line l)
		{
			if(parallel(l))
				return null;
			double x = (b * l.c - c * l.b) / (a * l.b - b * l.a);
			double y;
			if(Math.abs(b) < EPS)
				 y = -l.a * x - l.c;
			else
				y = -a * x - c;

			return new Point(x, y);
		}

		Point closestPoint(Point p)
		{
			if(Math.abs(b) < EPS) return new Point(-c, p.y);
			if(Math.abs(a) < EPS) return new Point(p.x, -c);
			return intersect(new Line(p, 1 / a));
		}

	}

   public static class Vector {

		double x, y;

		Vector(double a, double b) { x = a; y = b; }

		Vector(Point a, Point b) { this(b.x - a.x, b.y - a.y); }

		Vector scale(double s) { return new Vector(x * s, y * s); }              //s is a non-negative value

		double dot(Vector v) { return (x * v.x + y * v.y); }

		double cross(Vector v) { return x * v.y - y * v.x; }

		double norm2() { return x * x + y * y; }

		Vector reverse() { return new Vector(-x, -y); }

		Vector normalize()
		{
			double d = Math.sqrt(norm2());
			return scale(1 / d);
		}
	}

   static class Point implements Comparable<Point>{

		static final double EPS = 1e-9;

		double x, y;

		Point(double a, double b) { x = a; y = b; }

		public int compareTo(Point p)
		{
			if(Math.abs(x - p.x) > EPS) return x > p.x ? 1 : -1;
			if(Math.abs(y - p.y) > EPS) return y > p.y ? 1 : -1;
			return 0;
		}
		static double angle(Point a, Point o, Point b)  // angle AOB
		{
			Vector oa = new Vector(o, a), ob = new Vector(o, b);
			return Math.acos(oa.dot(ob) / Math.sqrt(oa.norm2() * ob.norm2()));
		}
		static boolean ccw(Point p, Point q, Point r)
		{
			return new Vector(p, q).cross(new Vector(p, r)) > 0;
		}

		public double dist(Point p) { return Math.sqrt(sq(x - p.x) + sq(y - p.y)); }

		static double sq(double x) { return x * x; }

		Point rotate(double angle)
		{
			double c = Math.cos(angle), s = Math.sin(angle);
			return new Point(x * c - y * s, x * s + y * c);
		}
		// for integer points and rotation by 90 (counterclockwise) : swap x and y, negate x

		boolean between(Point p, Point q)
		{
			return x < Math.max(p.x, q.x) + EPS && x + EPS > Math.min(p.x, q.x)
					&& y < Math.max(p.y, q.y) + EPS && y + EPS > Math.min(p.y, q.y);
		}

		//returns true if it is on the line defined by a and b

		//returns true if it is on the ray whose start point is a and passes through b
		// Another way: find closest point and calculate the distance between it and p
	}

	static class Scanner {
		StringTokenizer st;
		BufferedReader br;

		public Scanner(InputStream s) {
			br = new BufferedReader(new InputStreamReader(s));
		}

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

		public Scanner(String file) throws FileNotFoundException {
			br = new BufferedReader(new FileReader(file));
		}

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

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

		public String nextLine() throws IOException {
			return br.readLine();
		}

		public long nextlong() throws IOException {
			String x = next();
			StringBuilder sb = new StringBuilder("0");
			long res = 0, f = 1;
			boolean dec = false, neg = false;
			int start = 0;
			if (x.charAt(0) == '-') {
				neg = true;
				start++;
			}
			for (int i = start; i < x.length(); i++)
				if (x.charAt(i) == '.') {
					res = Long.parseLong(sb.toString());
					sb = new StringBuilder("0");
					dec = true;
				} else {
					sb.append(x.charAt(i));
					if (dec)
						f *= 10;
				}
			res += Long.parseLong(sb.toString()) / f;
			return res * (neg ? -1 : 1);
		}

		public boolean ready() throws IOException {
			return br.ready();
		}

	}
}


/* Shubhang Verma */
import java.io.*;
import java.math.*;
import java.util.*;
public class Main {

    public static void main(String[] args)
    {
        InputStream inputstream = System.in;
        OutputStream outputstream = System.out;
        InputReader in = new InputReader(inputstream);
        OutputWriter out = new OutputWriter(outputstream);
        mysolver mysol = new mysolver();
        mysol.solve(in, out);
        out.close();
    }
}
class node implements Comparable<node>{
	int count;
	long value;
	public int compareTo(node t)
	{
		if(this.value == t.value)
			return 0;
		else if(this.value < t.value)
			return -1;
		else
			return 1;
	}
}
class mysolver {
	public long mod = 1000000007;
	int M,N;
	boolean bpm(boolean bpGraph[][], int u, boolean seen[], int matchR[])
	{
	    for (int v = 0; v < N; v++)
	    {
	        if (bpGraph[u][v] && !seen[v])
	        {
	            seen[v] = true;
	            if (matchR[v] < 0 || bpm(bpGraph, matchR[v], seen, matchR))
	            {
	                matchR[v] = u;
	                return true;
	            }
	        }
	    }
	    return false;
	}

	int maxBPM(boolean bpGraph[][])
	{
	    int matchR[] = new int[N];
	    Arrays.fill(matchR,-1);
	    int result = 0;
	    for (int u = 0; u < M; u++)
	    {
	        boolean seen[] = new boolean[N];
	        if (bpm(bpGraph, u, seen, matchR))
	            result++;
	    }
	    return result;
	}

    public void solve(InputReader in,OutputWriter out)
    {
    	PrintWriter pout = new PrintWriter(new BufferedOutputStream(System.out));
    	int n = in.readInt();
    	int m = in.readInt();
    	boolean eg[][] = new boolean[n][n];
    	for(int i=0;i<n;i++)
    	{
    		Arrays.fill(eg[i],false);
    	}
    	for(int i=0;i<m;i++)
    	{
    		int x = in.readInt()-1;
    		int y = in.readInt()-1;
    		eg[x][y] = true;
    	}

    	int minimum = Integer.MAX_VALUE;

    	for(int i=0;i<n;i++)
    	{

        	int ct = 0;

    		int addedges =0;
    		if(eg[i][i] == false)
    		{
    			addedges++;
    		}
    		else
    		{
    			ct++;
    		}

    		for(int j=0;j<n;j++)
    		{
    			if(j!=i && eg[i][j]==false)
    			{
    				addedges++;
    			}
    			else if(j!=i && eg[i][j] == true)
    			{
    				ct++;
    			}
    			if(j!=i && eg[j][i]==false)
    			{
    				addedges++;
    			}
    			else if(j!=i && eg[j][i] == true)
    			{
    				ct++;
    			}
    		}
    		//m - ct

    		boolean row[] = new boolean[n];
    		boolean col[] = new boolean[n];
    		for(int j=0;j<n;j++)
    		{
    			row[j] = eg[i][j];
    			col[j] = eg[j][i];
    			eg[i][j] = false;
    			eg[j][i] = false;
    		}

    		N = n;
    		M = n;

//    		for(int I=0;I<n;I++)
//    		{
//    			for(int J=0;J<n;J++)
//    			{
//    				System.out.print(eg[I][J]+" ");
//    			}
//    			System.out.println();
//    		}
    		//System.out.println();
    		int matching = maxBPM(eg);
    		//System.out.println(matching);
    		addedges += n - 1 + m - ct - 2*matching;
    		minimum = Math.min(minimum,addedges);
    		for(int j=0;j<n;j++)
    		{
    			eg[i][j] = row[j];
    			eg[j][i] = col[j];
    		}

    	}

    	System.out.println(minimum);

        pout.close();
    }

}
class InputReader {
    private InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;
    private SpaceCharFilter filter;

    public InputReader(InputStream stream) {
        this.stream = stream;
    }

    public int read() {
        if (numChars == -1)
            throw new InputMismatchException();
        if (curChar >= numChars) {
            curChar = 0;
            try {
                numChars = stream.read(buf);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (numChars <= 0)
                return -1;
        }
        return buf[curChar++];
    }

    public int readInt() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        int res = 0;
        do {
            if (c < '0' || c > '9')
                throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public String readString() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        StringBuilder res = new StringBuilder();
        do {
            res.appendCodePoint(c);
            c = read();
        } while (!isSpaceChar(c));
        return res.toString();
    }

    public boolean isSpaceChar(int c) {
        if (filter != null)
            return filter.isSpaceChar(c);
        return isWhitespace(c);
    }

    public static boolean isWhitespace(int c) {
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }

    public String next() {
        return readString();
    }

    public interface SpaceCharFilter {
        public boolean isSpaceChar(int ch);
    }
}

class OutputWriter {
    private final PrintWriter writer;

    public OutputWriter(OutputStream outputStream) {
        writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
    }

    public OutputWriter(Writer writer) {
        this.writer = new PrintWriter(writer);
    }

    public void close() {
        writer.close();
    }

    public void printLine(int i) {
        writer.println(i);
    }
}

class IOUtils {

    public static void readIntArrays(InputReader in, int[]... arrays) {
        for (int i = 0; i < arrays[0].length; i++) {
            for (int j = 0; j < arrays.length; j++)
                arrays[j][i] = in.readInt();
        }
    }

    }


import java.io.*;
import java.lang.reflect.Array;
import java.math.BigDecimal;
import java.sql.Time;
import java.util.*;

import java.math.BigInteger;

import static java.lang.Math.*;
import static java.math.BigInteger.*;
import static java.util.Arrays.*;

public class Main{

    void run(){
        Locale.setDefault(Locale.US);
        boolean oj = System.getProperty("ONLINE_JUDGE") != null;
//        boolean oj = true;
        try{
            if( oj ){
                sc  = new FastScanner( new InputStreamReader(System.in  ) );
                out = new PrintWriter(   new OutputStreamWriter(System.out) );
            } else{
                sc  = new FastScanner(new FileReader("in.txt") );
//                sc  = new FastScanner(new FileReader("D:\\JavaOlymp\\FatalError\\output.txt") );
                out = new PrintWriter(   new FileWriter("out.txt") );
            }
        } catch (Exception e) {
            System.exit(-1);
        }
        long tB = System.currentTimeMillis();
        solve();
        if( !oj ) System.err.println( "Time: " + (System.currentTimeMillis()-tB)/1e3 );
        out.flush();
    }

    class FastScanner{
        BufferedReader br;
        StringTokenizer st = new StringTokenizer("");
        FastScanner( InputStreamReader a ){
            br = new BufferedReader(a);
        }
        FastScanner( FileReader a ){
            br = new BufferedReader(a);
        }
        String next(){
            while( !st.hasMoreTokens() )
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    return null;
                }
            return st.nextToken();
        }
        String readLine(){
            try {
                return br.readLine();
            } catch (Exception e) {
                return null;
            }
        }
        int nextInt(){ return Integer.parseInt(next()); }
        long nextLong(){ return Long.parseLong(next()); }
    }

    FastScanner sc;
    PrintWriter out;

    public static void main(String[] args){
        new Main().run();
//        new Thread( null, new Runnable() {
//            @Override
//            public void run() {
//                new Main().run();
//            }
//            }, "LOL", 256L * 1024 * 1024 / 2 ).run();
//        }, "LOL", 2000 * 1024 * 1024 ).run();
    }

    void TLE(){ for(;;); }

    void MLE(){
        int[][] adj = new int[1024*1024][];
        for( int i = 0; i < adj.length; ++i )
            adj[i] = new int[1024*1024];
    }

    void exit( int val ){
        out.flush();
        System.exit(val);
    }
    //////////////////////////////////////////////////////////////////////////////////////////

    int n, m;
    boolean[][] grid;
    ArrayList<Integer>[] gr;
    int c;
    int[] mt;
    boolean[] u;

    boolean try_kuhn( int v ){
        if( u[v] ) return false;
        u[v] = true;
        for( int to : gr[v] ){
            if( to == c || !grid[v][to] ) continue;
            if( mt[to]==-1 || try_kuhn(mt[to]) ){
                mt[to] = v;
                return true;
            }
        }
        return false;
    }

    void solve(){
        n = sc.nextInt();
        m = sc.nextInt();
        grid = new boolean[n+1][n+1];
        gr = new ArrayList[n+1];
        for( int v = 1; v <= n; ++v ) gr[v] = new ArrayList<Integer>();
        for( int it = 0; it < m; ++it ){
            int a = sc.nextInt();
            int b = sc.nextInt();
            grid[a][b] = true;
            gr[a].add(b);
        }

        int ans = Integer.MAX_VALUE;
        for( c = 1; c <= n; ++c ){
            int curAns = 0;
            for( int v = 1; v <= n; ++v )
                if( v != c ){
                    if( !grid[c][v] ) ++curAns;
                    if( !grid[v][c] ) ++curAns;
                }
            if( !grid[c][c] ) ++curAns;

            mt = new int[n+1];
            fill( mt, -1 );
            for( int i = 1; i <= n; ++i )
                if( i != c ){
                    u = new boolean[n+1];
                    try_kuhn(i);
                }

            int szMt = 0;
            for( int i = 1; i <= n; ++i )
                if( mt[i] != -1 )
                    ++szMt;
            curAns += n - 1 - szMt;

            for( int a = 1; a <= n; ++a ){
            for( int b = 1; b <= n; ++b ){
                if( a==c || b==c || !grid[a][b]
                ) continue;
                if(!( a==mt[b] ))
                    ++curAns;
            }
            }

//            out.printf( "%d %d\n", c, curAns );
            ans = min( ans, curAns );
        }
        out.println( ans );
    }

}


import java.io.IOException;
import java.io.InputStream;
import java.util.Arrays;
import java.util.InputMismatchException;
import java.util.LinkedList;

public class D {
    static LinkedList<Integer>[] E;
    static int[] M;
    static boolean[] visited;
    static int n;
    static int center;

    public static boolean match(int x) {
        if (visited[x])
            return false;
        visited[x] = true;
        for (int y : E[x])
            if (y != center && (M[y] == -1 || match(M[y]))) {
                M[y] = x;
                return true;
            }
        return false;
    }

    public static int maxMatch() {
        int res = 0;
        Arrays.fill(M, -1);
        for (int i = 0; i < n; i++) {
            Arrays.fill(visited, false);
            if (i != center && match(i))
                res++;
        }
        return res;
    }

    public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        n = in.readInt();
        int m = in.readInt();
        E = new LinkedList[n];
        M = new int[n];
        boolean[][] C = new boolean[n][n];
        visited = new boolean[n];
        for (int i = 0; i < n; i++)
            E[i] = new LinkedList<Integer>();
        for (int i = 0; i < m; i++) {
            int x = in.readInt() - 1;
            int y = in.readInt() - 1;
            C[x][y] = true;
            E[x].add(y);
        }
        int min = Integer.MAX_VALUE;
        for (int i = 0; i < n; i++) {
            int res = 0;
            int all = 0;
            for (int j = 0; j < n; j++)
                if (j != i) {
                    all += E[j].size();
                    if (!C[i][j])
                        res++;
                    if (!C[j][i])
                        res++;
                    else
                        all--;
                }
            if (!C[i][i])
                res++;
            center = i;
            int match = maxMatch();
            res += (all - match) + (n - match - 1);
            min = Math.min(min, res);
        }
        System.out.println(min);
    }
}

class InputReader {

    private InputStream stream;
    private byte[] buf = new byte[1000];
    private int curChar, numChars;

    public InputReader(InputStream stream) {
        this.stream = stream;
    }

    private int read() {
        if (numChars == -1)
            throw new InputMismatchException();
        if (curChar >= numChars) {
            curChar = 0;
            try {
                numChars = stream.read(buf);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (numChars <= 0)
                return -1;
        }
        return buf[curChar++];
    }

    public int readInt() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        int res = 0;
        do {
            if (c < '0' || c > '9')
                throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public long readLong() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        long res = 0;
        do {
            if (c < '0' || c > '9')
                throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public String readString() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        StringBuffer res = new StringBuffer();
        do {
            res.appendCodePoint(c);
            c = read();
        } while (!isSpaceChar(c));
        return res.toString();
    }

    private boolean isSpaceChar(int c) {
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }

    private String readLine0() {
        StringBuffer buf = new StringBuffer();
        int c = read();
        while (c != '\n' && c != -1) {
            buf.appendCodePoint(c);
            c = read();
        }
        return buf.toString();
    }

    public String readLine() {
        String s = readLine0();
        while (s.trim().length() == 0)
            s = readLine0();
        return s;
    }

    public String readLine(boolean ignoreEmptyLines) {
        if (ignoreEmptyLines)
            return readLine();
        else
            return readLine0();
    }

    public char readCharacter() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        return (char) c;
    }

    public double readDouble() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        double res = 0;
        while (!isSpaceChar(c) && c != '.') {
            if (c == 'e' || c == 'E')
                return res * Math.pow(10, readInt());
            if (c < '0' || c > '9')
                throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = read();
        }
        if (c == '.') {
            c = read();
            double m = 1;
            while (!isSpaceChar(c)) {
                if (c == 'e' || c == 'E')
                    return res * Math.pow(10, readInt());
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                m /= 10;
                res += (c - '0') * m;
                c = read();
            }
        }
        return res * sgn;
    }
}


import java.io.Reader;
import java.util.Arrays;
import java.util.InputMismatchException;
import java.util.ArrayList;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.BufferedReader;
import java.util.List;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Writer;
import java.io.IOException;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Niyaz Nigmatullin
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		FastScanner in = new FastScanner(inputStream);
		FastPrinter out = new FastPrinter(outputStream);
		TaskD solver = new TaskD();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskD {
    public void solve(int testNumber, FastScanner in, FastPrinter out) {
        int n = in.nextInt();
        int m = in.nextInt();
        int[] from = new int[m];
        int[] to = new int[m];
        for (int i = 0; i < m; i++) {
            from[i] = in.nextInt() - 1;
            to[i] = in.nextInt() - 1;
        }
        int ans = Integer.MAX_VALUE;
        for (int i = 0; i < n; i++) {
            KuhnMatchingGraph g = new KuhnMatchingGraph(n, n);
            int count = 0;
            for (int j = 0; j < m; j++) {
                if (from[j] != i && to[j] != i) {
                    g.addEdge(from[j], to[j]);
                    ++count;
                }
            }
            int cur = (n - 1 + count) - 2 * g.getMaximalMatching();
            boolean[] a = new boolean[n];
            boolean[] b = new boolean[n];
            for (int j = 0; j < m; j++) {
                if (from[j] == i) {
                    a[to[j]] = true;
                }
                if (to[j] == i) {
                    b[from[j]] = true;
                }
            }
            for (int j = 0; j < n; j++) {
                if (j == i) {
                    if (!a[j]) ++cur;
                } else {
                    if (!a[j]) ++cur;
                    if (!b[j]) ++cur;
                }
            }
            ans = Math.min(ans, cur);
        }
        out.println(ans);
    }
}

class FastScanner extends BufferedReader {

    public FastScanner(InputStream is) {
        super(new InputStreamReader(is));
    }

    public int read() {
        try {
            int ret = super.read();
//            if (isEOF && ret < 0) {
//                throw new InputMismatchException();
//            }
//            isEOF = ret == -1;
            return ret;
        } catch (IOException e) {
            throw new InputMismatchException();
        }
    }

    static boolean isWhiteSpace(int c) {
        return c >= 0 && c <= 32;
    }

    public int nextInt() {
        int c = read();
        while (isWhiteSpace(c)) {
            c = read();
        }
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        int ret = 0;
        while (c >= 0 && !isWhiteSpace(c)) {
            if (c < '0' || c > '9') {
                throw new NumberFormatException("digit expected " + (char) c
                        + " found");
            }
            ret = ret * 10 + c - '0';
            c = read();
        }
        return ret * sgn;
    }

    public String readLine() {
        try {
            return super.readLine();
        } catch (IOException e) {
            return null;
        }
    }

}

class FastPrinter extends PrintWriter {

    public FastPrinter(OutputStream out) {
        super(out);
    }

}

class KuhnMatchingGraph {

    int n;
    int m;
    List<Integer>[] edges;
    int[] p1;
    int[] p2;
    int[] was;
    int VER;

    public KuhnMatchingGraph(int n, int m) {
        this.n = n;
        this.m = m;
        edges = new ArrayList[n];
        for (int i = 0; i < n; i++) {
            edges[i] = new ArrayList<Integer>(2);
        }
    }

    public void addEdge(int from, int to) {
        edges[from].add(to);
    }

    public int getMaximalMatching() {
        p1 = new int[n];
        p2 = new int[m];
        was = new int[n];
        VER = 0;
        Arrays.fill(p1, -1);
        Arrays.fill(p2, -1);
        int answer = 0;
        for (int i = 0; i < n; i++) {
            for (int j : edges[i]) {
                if (p2[j] < 0) {
                    p2[j] = i;
                    p1[i] = j;
                    answer++;
                    break;
                }
            }
        }
        for (int i = 0; i < n; i++) {
            if (p1[i] >= 0) {
                continue;
            }
            VER++;
            if (dfs(i)) {
                answer++;
            }
        }
        return answer;
    }

    boolean dfs(int v) {
        if (was[v] == VER) {
            return false;
        }
        was[v] = VER;
        for (int i = 0; i < edges[v].size(); i++) {
            int e = edges[v].get(i);
            if (p2[e] < 0 || dfs(p2[e])) {
                p2[e] = v;
                p1[v] = e;
                return true;
            }
        }
        return false;
    }
}