Problem: Ford Prefect got a job as a web developer for a small company that makes towels. His current work task is to create a search engine for the website of the company. During the development process, he needs to write a subroutine for comparing strings S and T of equal length to be "similar". After a brief search on the Internet, he learned about the Hamming distance between two strings S and T of the same length, which is defined as the number of positions in which S and T have different characters. For example, the Hamming distance between words "permanent" and "pergament" is two, as these words differ in the fourth and sixth letters.

Moreover, as he was searching for information, he also noticed that modern search engines have powerful mechanisms to correct errors in the request to improve the quality of search. Ford doesn't know much about human beings, so he assumed that the most common mistake in a request is swapping two arbitrary letters of the string (not necessarily adjacent). Now he wants to write a function that determines which two letters should be swapped in string S, so that the Hamming distance between a new string S and string T would be as small as possible, or otherwise, determine that such a replacement cannot reduce the distance between the strings.

Help him do this!

Input

The first line contains integer n (1 ≤ n ≤ 200 000) — the length of strings S and T.

The second line contains string S.

The third line contains string T.

Each of the lines only contains lowercase Latin letters.

Output

In the first line, print number x — the minimum possible Hamming distance between strings S and T if you swap at most one pair of letters in S.

In the second line, either print the indexes i and j (1 ≤ i, j ≤ n, i ≠ j), if reaching the minimum possible distance is possible by swapping letters on positions i and j, or print "-1 -1", if it is not necessary to swap characters.

If there are multiple possible answers, print any of them.

Examples

Input

9
pergament
permanent


Output

1
4 6


Input

6
wookie
cookie


Output

1
-1 -1


Input

4
petr
egor


Output

2
1 2


Input

6
double
bundle


Output

2
4 1

Note

In the second test it is acceptable to print i = 2, j = 3.

Solution (in JAVA):

Solution:
import java.awt.Container;
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.PriorityQueue;
import java.util.Queue;
import java.util.Random;
import java.util.Scanner;
import java.util.Stack;
import java.util.StringTokenizer;
import java.util.TreeSet;
import java.util.concurrent.LinkedBlockingDeque;

import javax.swing.border.Border;

public class a {

	public static long mod = (long) Math.pow(10, 9) + 7;

	private static class node implements Comparable<node> {
		String ans;

		node(String an) {
			ans = an;
		}

		@Override
		public int compareTo(node o) {
			if (o.ans.length() > ans.length())
				return -1;
			while (o.ans.length() < ans.length())
				return 1;
			for (int i = 0; i < o.ans.length(); i++) {
				if (o.ans.charAt(i) > ans.charAt(i))
					return -1;
				else if (o.ans.charAt(i) < ans.charAt(i))
					return 1;
			}

			return 1;

		}

	}

	public static class point {
		int screen;
		int order;

		point(int x, int y) {
			screen = x;
			order = y;

		}

	}

	public static int ch(long y) {
		int r = Long.bitCount(y);
		return r;
	}

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

		return gcd(y, x % y);
	}

	public static boolean ch[] = new boolean[10000005];
	public static ArrayList<Integer> prime = new ArrayList();

	// public static Queue<Integer> pp;

	public static void sieve(int k) {
		ch[0] = ch[1] = true;

		for (int i = 2; i <= k; i++) {
			if (!ch[i]) {
				prime.add(i);
				// pp.add(i);
				for (long j = (long) i * (long) i; j <= k; j += i) {
					ch[(int) j] = true;
				}
			}
		}

	}

	public static long pw(int x, int power, int mod) {
		if (power == 1)
			return x % mod;
		else if (power % 2 == 0)
			return pw((x % mod * x % mod) % mod, power / 2, mod);
		else
			return (pw(x, power - 1, mod) % mod * x % mod) % mod;

	}

	public static String addToString(String a, int index, char b) {
		String ans = "";
		for (int i = 0; i < a.length(); i++) {
			if (i == index) {
				ans += b;
				index = -1;
				i--;
				continue;
			}
			ans += a.charAt(i);
		}
		return ans;
	}

	public static int bit[];

	public static void add(int idx, int cost) {
		while (idx < bit.length) {
			bit[idx] += cost;
			idx += (idx & -idx);
		}

	}

	public static int get(int idx) {
		int res = 0;
		while (idx > 0) {
			res += bit[idx];
			idx -= (idx & -idx);
		}
		return res;
	}

	public static int dx[] = { 0, 1, 0, -1 };
	public static int dy[] = { 1, 0, -1, 0 };

	public static ArrayList<Integer> solve(ArrayList<Integer> coff,
			ArrayList<Integer> power) {
		ArrayList<Integer> ans = new ArrayList();
		for (int x = -100; x < 101; x++) {
			long t = 0;
			for (int j = 0; j < coff.size(); j++) {
				t += coff.get(j) * Math.pow(x, power.get(j));
			}
			if (t == 0)
				ans.add(x);
		}
		return ans;
	}

	public static int dp[][];
	public static int n;
	public static int a[];
	public static int next[];

	public static int solve(int one, int two) {
		if (two == -1 || one == -1)
			return 0;
		if (dp[one][two] != -1)
			return dp[one][two];

		if (next[one] > two)
			return dp[one][two] = solve(two, next[one]) + 1;
		else
			return dp[one][two] = solve(next[one], two);

	}

	public static void main(String[] args) throws IOException {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		// BufferedReader in = new BufferedReader(new FileReader(
		// "corporate_gifting.txt"));
		StringBuilder qq = new StringBuilder();
		PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
		// PrintWriter out = new PrintWriter(new FileWriter("out.txt"));
		// System.out.println('a' - 'A');

		int n = Integer.parseInt(in.readLine());
		String one = in.readLine();
		String two = in.readLine();
		int a[][] = new int[26][26];
		int b[][] = new int[26][26];
		int min = 0;
		for (int i = 0; i < one.length(); i++) {
			if (one.charAt(i) != two.charAt(i)) {
				min++;
				a[one.charAt(i) - 'a'][two.charAt(i) - 'a']++;
				b[two.charAt(i) - 'a'][one.charAt(i) - 'a']++;
			}
		}
		boolean t = false;

		int i1 = -1;
		int i2 = -1;
		int f1 = -1;
		int f2 = -1;
		for (int i = 0; i < 26 && !t; i++) {
			for (int j = 0; j < 26; j++) {
				if (i == j)
					continue;
				if (a[i][j] > 0 && a[j][i] > 0) {
					min -= 2;
					f1 = i;
					f2 = j;
					t = true;
					break;

				}
			}
		}
		if (t) {
			for (int i = 0; i < one.length(); i++) {
				if (one.charAt(i) - 'a' == f1 && two.charAt(i) - 'a' == f2) {
					i1 = i + 1;

				} else if (one.charAt(i) - 'a' == f2
						&& two.charAt(i) - 'a' == f1) {
					i2 = i + 1;

				}
			}
			System.out.println(min);
			System.out.println(i1 + " " + i2);
			return;
		}
		boolean o = false;
		int f3 = -1;
		int f4 = -1;
		for (int i = 0; i < 26 && !o; i++) {
			for (int j = 0; j < 26 && !o; j++) {
				if (a[i][j] > 0) {
					for (int j2 = 0; j2 < 26 && !o; j2++) {
						if (a[j2][i] > 0) {
							f1 = i;
							f2 = j;
							f3 = j2;
							f4 = i;
							o = true;
							break;
						}
					}

					for (int j2 = 0; j2 < 26 && !o; j2++) {
						if (a[j][j2] > 0) {
							f1 = i;
							f2 = j;
							f3 = j;
							f4 = j2;
							o = true;
							break;
						}
					}
				}
			}
		}

		if (o) {
			min--;
			for (int i = 0; i < one.length(); i++) {
				if (one.charAt(i) - 'a' == f1 && two.charAt(i) - 'a' == f2) {
					i1 = i + 1;
				} else if (one.charAt(i) - 'a' == f3
						&& two.charAt(i) - 'a' == f4) {
					i2 = i + 1;
				}
			}
			System.out.println(min);
			System.out.println(i1+" "+i2);
			return;
		}
		System.out.println(min);
		System.out.println(-1+ " "+-1);
		

		out.close();

	}
}