8587340257
 9
 81
 27
 1408514752349
 25
 49380563
 266418
 319757451841
 6599669076000
 8
 1000000000000
 30971726
 274875809788
 64
 34280152201
 236
 472670214391
 7938986881993
 44
 4
 388
 2
 802241960524
 3047527844089
 5
 12
 614125
 1716443237161
 48855707
 99
 9999925100701
 5839252225
 3
 50
 1307514188557
 9999926826034
 1468526771489
 2975
 8110708459517
 401120980262
 5138168457911
 1245373417369
 128
 16
 2000000014
 445538663413
 57461344602
 324
 7420738134810

1
9409 2 1
9 1
9 1
72361 2 1
289 1
6 1
289 1
4 1
4 1
4 2 1
4 1
4 2 1
4 1
23020027 1
378028993 1
4 2 1
4 1
0 1
4 2 1
0 1
4 1
25 1
5329 1
2603 1
9 1
0 1
25 1
0 1
10 1
39283 2 1
613783 1
25 2 2 2 1
908209 1
4 1
4 2 1
0 1
6 1
4 1
6
import java.util.List;
import java.io.IOException;
import java.util.Arrays;
import java.io.PrintStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.LinkedList;
import java.io.InputStream;

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

class TaskC {
    public void solve(int testNumber, InputReader jin, PrintWriter jout) {
        long x = jin.int64();
        long v = solve(x);
        if(v == -1) {
            jout.println(2);
        } else {
            jout.println(1);
            jout.println(v);
        }
    }

    long solve(long x) {
        int[] primeList = PrimeNumbers.primes((int)1e7);
        int r = 2;
        int cp = 0;
        long found = 1;
        long orgx = x;
        while(r > 0 && x > 0 && cp < primeList.length) {
            if(x % primeList[cp] != 0) cp++;
            else {
                r--; found *= primeList[cp];
                x /= primeList[cp];
            }
        }
        System.err.println(r + " " + found);
        if(r > 0) return 0;
        if(found == orgx) return -1;
        return found;
    }
}

class InputReader {
    private static final int bufferMaxLength = 1024;
    private InputStream in;
    private byte[] buffer;
    private int currentBufferSize;
    private int currentBufferTop;
    private static final String tokenizers = " \t\r\f\n";
    
    public InputReader(InputStream stream) {
        this.in = stream;
        buffer = new byte[bufferMaxLength];
        currentBufferSize = 0;
        currentBufferTop = 0;
    }
    
    private boolean refill() {
        try {
            this.currentBufferSize = this.in.read(this.buffer);
            this.currentBufferTop = 0;
        } catch(Exception e) {}
        return this.currentBufferSize > 0;
    }
    
    
    private Byte readChar() {
        if(currentBufferTop < currentBufferSize) {
            return this.buffer[this.currentBufferTop++];
        } else {
            if(!this.refill()) {
                return null;
            } else {
                return readChar();
            }
        }
    }
    
    
    public String token()  {
        StringBuffer tok = new StringBuffer();
        Byte first;
        while((first = readChar()) != null && (tokenizers.indexOf((char) first.byteValue()) != -1));
        if(first == null) return null;
        tok.append((char)first.byteValue());
        while((first = readChar()) != null && (tokenizers.indexOf((char) first.byteValue()) == -1)) {
            tok.append((char)first.byteValue());
        }
        return tok.toString();
    }
    
    public Long int64() throws NumberFormatException {
        String tok = token();
        return tok == null? null : Long.parseLong(tok);
    }
    
}

class PrimeNumbers {

    private static boolean[] sieve(int max) {
        boolean[] primes = new boolean[max + 1];
        Arrays.fill(primes, true);
        primes[0] = primes[1] = false;
        for(int i = 0; i <= max; i++) {
            if(primes[i]) {
                int factor = i;
                while(i * (long) factor <= max) {
                    primes[(i * factor)] = false;
                    factor++;
                }
            }
        }
        return primes;
    }

    public static int[] primes(int max) {
        boolean[] primesChecker = PrimeNumbers.sieve(max);
        List<Integer> primeList = new LinkedList<Integer>();
        for(int i = 0; i < max; i++) {
            if(primesChecker[i]) {
                primeList.add(i);
            }
        }
        int ci = 0;
        int[] arr = new int[primeList.size()];
        for(Integer x: primeList) arr[ci++] = x;
        return arr;
    }
}

