codeparrot/codecomplex huggingface dataset:
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.InputStreamReader;
import java.io.IOException;
import java.util.InputMismatchException;
import java.io.PrintStream;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Reader;
import java.io.Writer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Nipuna Samarasekara
 */
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);
		TaskA solver = new TaskA();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskA {
    /////////////////////////////////////////////////////////////

    public void solve(int testNumber, FastScanner in, FastPrinter out) {
    int n=in.nextInt();
        if (n%2==0){
            if (n%4==0)
                out.println(n/2+" "+n/2);
            else out.println(6+" "+(n-6));

        }
        else{
            out.println(9+" "+(n-9));
        }

    }
}

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);
    }

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


}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.Scanner;

public class Main 
{   
    public static void main(String[] args) 
    {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        
        int one, two;
        if(n%2 == 0)
        {
            one = two = n/2;
            if(one%2 != 0 && two%2 != 0)
            {
                one--;
                two++;
            }
        }
        else
        {
            one = n - 9;
            two = 9;
        }
        
        System.out.println(one+" "+two);
        
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        if (n % 2 == 0) {
            System.out.println((n - 4) + " " + (n - (n - 4)));
        } else {
            System.out.println((n - 9) + " " + (n - (n - 9)));
        }
    }

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Anirudh Rayabharam (anirudhrb@yandex.com)
 */
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(1, in, out);
		out.close();
	}
}

class TaskA {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        int n = in.nextInt();
        if (n % 2 == 0) {
            out.println("4 " + (n - 4));
        } else {
            out.println("9 " + (n - 9));
        }
    }
}

class InputReader {
    public BufferedReader reader;
    private int tokenCount, nextTokenIndex;
    private String[] tokens;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream));
        tokenCount = nextTokenIndex = 0;
    }

    public String next() {
        String nextLine;
        if (nextTokenIndex == tokenCount) {
            try {
                nextLine = reader.readLine();
                nextTokenIndex = 0;
                tokens = nextLine.split("\\s");
                tokenCount = tokens.length;
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }

        return tokens[nextTokenIndex++];
    }

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

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.IOException;
import java.util.Scanner;

/**
 * TODO: describe
 *
 * @author keks
 */
public class A {
    public static void main(String[] args) throws IOException {
        final Scanner sc = new Scanner(System.in);
        final int n = sc.nextInt();
        if (n % 2 == 0) {
            System.out.println(4 + " " + (n - 4));
        } else {
            System.out.println(9 + " " + (n - 9));
        }
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.*;
import java.io.*;
public class Cf270a {
    public static void main(String[] args) throws IOException {
        InputStreamReader fin = new InputStreamReader(System.in);
        Scanner scr = new Scanner(fin);
        int n = scr.nextInt();
        int x = 0;
        int y = 0;
        if (n%2 == 0) {
            x = 4;
            y = n - x;
        } else {
            x = 9;
            y = n - x;
        }
        PrintWriter fout = new PrintWriter(System.out);
        fout.print(x+" "+y);
        fout.flush();
        fout.close();
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;


public class TA {

	public void solve(long n) {
		long a = 0, b = 0;
		if (n % 2 == 0) {
			if (n % 4 == 0) {
				a = n / 2;
				b = n/ 2;
			} else {
				a = n / 2 - 1;
				b = n / 2 + 1;
			}
		} else {
			a = 4;
			b = n - a;
			while (b > 0 && (b % 3 != 0)) {
				a += 2;
				b = n - a;
			}
			
		}
		System.out.println(a + " " + b);
	}
	public static void main(String[] args) {
		FastScanner in = new FastScanner();
		
		new TA().solve(in.nextLong());
	}
	static class FastScanner {

		BufferedReader br;
		StringTokenizer st;

		public FastScanner(String s) {
			try {
				br = new BufferedReader(new FileReader(s));
			} catch (FileNotFoundException e) {
				e.printStackTrace();
			}
		}

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

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

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

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

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

	}

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.Scanner;

public class J472A {
	private static Scanner scan = new Scanner(System.in);
	public static void main(String[] args) {
		int a = scan.nextInt();
		if(a % 2 == 0) {
			System.out.println(4 + " " + (a - 4));//ż���4
		} else {
			System.out.println(9 + " " + (a - 9));//������
		}
	}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int a,b;
		if (n%2==0) {
			a = 4;
		}else{
			a = 9;
		}
		b = n - a;
		System.out.println(a + " " + b);
	}

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.Scanner;

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

        int n = in.nextInt();
        
        int a = n/2;
        int b = (n/2) + (n%2);
        
        if ((a%2!=0 && a%3!=0) || (b%2!=0 && b%3!=0)) {
            a--;
            b++;
        }
        
        if ((a%2!=0 && a%3!=0) || (b%2!=0 && b%3!=0)) {
            a--;
            b++;
        }

        System.out.println(a + " " + b);
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant

import java.util.Scanner;


public class composite {

  
    public static void main(String[] args) {
        int b;
        Scanner s3=new Scanner(System.in);
         b=s3.nextInt();
      
          if(b%2==0)
          {
              b=b-4;
              System.out.println(4+" "+b);
          }
          else
          {
              b=b-9;
              System.out.println(9+" "+b);
          }
      
    
}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.*;
import java.util.*;

public class A {

	BufferedReader in;
	StringTokenizer st;
	PrintWriter out;

	String next() throws IOException {
		while (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(in.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());
	}

	void solve() throws Exception {
		int n = nextInt();
		if(n%2==0)
			out.println("4 "+(n-4));
		else
			out.println("9 "+(n-9));
	}

	void run() {
		try {
			Locale.setDefault(Locale.US);
			in = new BufferedReader(new InputStreamReader(System.in));
			out = new PrintWriter(new OutputStreamWriter(System.out));
			solve();
			out.close();
		} catch (Exception e) {
			e.printStackTrace();
			System.exit(1);
		}
	}

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

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.*;
import java.util.*;

public class Main {
  // main
  public static void main(String [] args) throws IOException {
    // makes the reader and writer
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedOutputStream(System.out));
    
    // read in N
    int N = Integer.parseInt(f.readLine());
    
    // write to out
    if (N%2==0) out.println("4 "+(N-4));
    if (N%2==1) out.println("9 "+(N-9));
    
    // cleanup
    out.close();
    System.exit(0);
  }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.Scanner;


public class A470 {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		
	Scanner sc = new Scanner(System.in);
	
	int n=sc.nextInt();
	
	int start=4;
	
	
	while(true){
		
		if((start%2==0||start%3==0)&&((n-start)%2==0||(n-start)%3==0))
		{
			System.out.println(start+" "+(n-start));
			return;
		}
		else 
		start++;
		
		
		
	}
	
	
		
		
	}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashSet;
import java.util.StringTokenizer;


public class A {
	
	public static void main(String[] args) throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer tb;
		int n = Integer.parseInt(br.readLine());
		int x = 0,y=0;
		if(n%2==0){
			x = n-4;
			y = 4;
		}else{
			x = n-9;
			y = 9;
		}
		System.out.println(x+" "+y);
	}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
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;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author bdepwgjqet
 */
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);
		A solver = new A();
		solver.solve(1, in, out);
		out.close();
	}
}

class A {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        int number = in.nextInt();
        if((number & 1) == 0) {
            out.println(4+" "+(number-4));
        } else {
            out.println(9+" "+(number-9));
        }
    }
}

class InputReader {

    private final BufferedReader bufferedReader;
    private StringTokenizer stringTokenizer;

    public InputReader(InputStream in) {
        bufferedReader = new BufferedReader(new InputStreamReader(in));
        stringTokenizer = null;
    }

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

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

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

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

    public long nextLong() {
        return Long.parseLong(nextBlock());
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.*;
import java.util.*;
import java.math.*;

public class p472a {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        if (n % 2 == 0) {
            System.out.println("8 " + (n - 8));
        } else {
            System.out.println("9 " + (n - 9));
        }
    }
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.util.*;
public class A
{
	public static void main(String[] args)
	{
		Scanner in = new Scanner(System.in);
		
		int n = in.nextInt();
		
		if(n % 2 == 1)
		{
			System.out.println(9 + " " + (n - 9));
		}
		else
		{
			System.out.println(4 + " " + (n - 4));
		}
	}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.File;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.Collections;

public class Problem1 {

    public static void main(String[] args) throws IOException {
        // TODO Auto-generated method stub
        
        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
        long n=Long.parseLong(br.readLine());
        if(n%2==0){
            System.out.println(4+" "+(n-4));
        }
        else{
            System.out.println(9+" "+(n-9));
        }
        
    }

}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;


public class Test {
public static void main(String[] args) throws IOException{
	BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
	//StringTokenizer st=new StringTokenizer(bf.readLine());
	int n=Integer.parseInt(bf.readLine());
	
	if(n%2==0) System.out.println(4+" "+(n-4));
	else System.out.println(9+" "+(n-9));
	
}
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main{
    
    public static boolean isPrime(long num){
        int divisor = 2;
        boolean bandera = true;
        while(bandera && divisor<num) //ponemos el while con su condicion en este caso si bandera 
        { 
        if (num%divisor==0) {
            bandera=false;
            break;
        }else{
            divisor++; //igual si el divisor llego al numero q se capturo este sera primo 
        }
        }
        return bandera;
    }
    
    public static void main(String[] args) throws IOException {
        
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        int uno = 4;
        int dos = n-4;

        while(isPrime(dos) || isPrime(uno)){
            dos--;
            uno++;
        }

        System.out.println(uno+" "+dos);
        
    }
    
}
// Problem: 472_A. Design Tutorial: Learn from Math
// Time complexity: constant
/* package whatever; // don't place package name! */

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

/* Name of the class has to be "Main" only if the class is public. */
public class Ideone
{
    public static void main (String[] args) throws java.lang.Exception
    {
     int n,a,b;
     Scanner obj=new Scanner(System.in);
    
     n=obj.nextInt();
    
     if(n%4==0){a=n/2;b=n/2;System.out.println(a+" "+b);}
     else if(n%2==0 && n%4!=0)
     {a=n/2-1;b=n/2+1;System.out.println(a+" "+b);}
     
     else if(n%2!=0)
     {  a=4;b=0;
       while(b!=1)
       { b=n-a;
         if(b%3==0){ System.out.println(a+" "+b);break; }
         else{a=a+2;}
       }
     }
    }
}
// Problem: 343_A. Rational Resistance
// Time complexity: constant
import java.io.*;
import java.util.*;

public class A {

	FastScanner in;
	PrintWriter out;

	void solve() {
		long a = in.nextLong(), b = in.nextLong();

		long ans = 0;
		while (true) {
			long div = a / b;
			
			ans += div;
			a -= div * b;
			
			if (a == 0) {
				break;
			}
			
			long tmp = a;
			a = b;
			b = tmp;
		}
		
		out.println(ans);
	}
	

	void run() {
		in = new FastScanner();
		out = new PrintWriter(System.out);
		solve();
		out.close();
	}

	class FastScanner {
		BufferedReader br;
		StringTokenizer st;

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

		String nextToken() {
			while (st == null || !st.hasMoreElements()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

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

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

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

	public static void main(String[] args) {
		new A().run();
	}
}
// Problem: 343_A. Rational Resistance
// Time complexity: constant
import java.util.Scanner;

public class A {
	public static final boolean DEBUG = false;
	Scanner sc;
	
	public void debug(Object o) {
		if (DEBUG) {
			int ln = Thread.currentThread().getStackTrace()[2].getLineNumber();
			String fn = Thread.currentThread().getStackTrace()[2].getFileName();
			System.out.println("(" + fn + ":" + ln+ "): " + o);
		}
	}
	
	public void pln(Object o) {
		System.out.println(o);
	}
	
	
	public void run() {
		sc = new Scanner(System.in);		
		long a = sc.nextLong();
		long b = sc.nextLong();
		long nr = 0;
		if (a < b) {
			long aux = a;
			a = b;
			b = aux;
		}
		while (a != 0 && b != 0) {
			nr += a / b;
			long c = a % b;
			a = b;
			b = c;
		}
		
		pln(nr);
		return;
		
	}
	public static void main(String[] args) {
		A t = new A();
		t.run();
	}
}
// Problem: 343_A. Rational Resistance
// Time complexity: constant
import java.io.*;
import java.util.*;

public class A {
  public static void main(String[] args){
    FastScanner sc = new FastScanner();
    long a = sc.nextLong();
    long b = sc.nextLong();
    long result = 0L;

    while(a != 0 && b != 0) {
      if(a > b) {
        result += a/b;
        a = a % b;
      } else {
        result += b/a;
        b = b % a;
      }

      long gcd = gcd(a, b);
      a /= gcd;
      b /= gcd;
    }

      System.out.println(result);
  }

  private static long gcd(long a, long b) {
    while(a != 0 && b != 0) {
      if(a < b) {
        long tmp = a;
        a = b;
        b = tmp;
      }
      a%=b;
    }
    return a + b;
  }

  public static class FastScanner {
    BufferedReader br;
    StringTokenizer st;

    public FastScanner(String s) {
      try {
        br = new BufferedReader(new FileReader(s));
      } catch (FileNotFoundException e) {
        e.printStackTrace();
      }
    }

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

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

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

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

    double nextDouble() {
      return Double.parseDouble(nextToken());
    }
  }
}
// Problem: 343_A. Rational Resistance
// Time complexity: constant
import java.io.*;
import java.math.*;
import java.util.*;

public class Main {
    long solve(long a, long b) {
        return b == 0 ? 0 : a / b + solve(b, a % b);
    }

    public void run() {
        try {
            long a = reader.nextLong();
            long b = reader.nextLong();
            writer.println(solve(a, b));
        } catch (IOException ex) {
        }
        writer.close();
    }

    InputReader reader;
    PrintWriter writer;

    Main() {
        reader = new InputReader();
        writer = new PrintWriter(System.out);
    }

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

}

class InputReader {
    BufferedReader reader;
    StringTokenizer tokenizer;

    InputReader() {
        reader = new BufferedReader(new InputStreamReader(System.in));
        tokenizer = new StringTokenizer("");
    }

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

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

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