Problem: After the fourth season Sherlock and Moriary have realized the whole foolishness of the battle between them and decided to continue their competitions in peaceful game of Credit Cards.

Rules of this game are simple: each player bring his favourite n-digit credit card. Then both players name the digits written on their cards one by one. If two digits are not equal, then the player, whose digit is smaller gets a flick (knock in the forehead usually made with a forefinger) from the other player. For example, if n = 3, Sherlock's card is 123 and Moriarty's card has number 321, first Sherlock names 1 and Moriarty names 3 so Sherlock gets a flick. Then they both digit 2 so no one gets a flick. Finally, Sherlock names 3, while Moriarty names 1 and gets a flick.

Of course, Sherlock will play honestly naming digits one by one in the order they are given, while Moriary, as a true villain, plans to cheat. He is going to name his digits in some other order (however, he is not going to change the overall number of occurences of each digit). For example, in case above Moriarty could name 1, 2, 3 and get no flicks at all, or he can name 2, 3 and 1 to give Sherlock two flicks.

Your goal is to find out the minimum possible number of flicks Moriarty will get (no one likes flicks) and the maximum possible number of flicks Sherlock can get from Moriarty. Note, that these two goals are different and the optimal result may be obtained by using different strategies.

Input

The first line of the input contains a single integer n (1 ≤ n ≤ 1000) — the number of digits in the cards Sherlock and Moriarty are going to use.

The second line contains n digits — Sherlock's credit card number.

The third line contains n digits — Moriarty's credit card number.

Output

First print the minimum possible number of flicks Moriarty will get. Then print the maximum possible number of flicks that Sherlock can get from Moriarty.

Examples

Input

3
123
321


Output

0
2


Input

2
88
00


Output

2
0

Note

First sample is elaborated in the problem statement. In the second sample, there is no way Moriarty can avoid getting two flicks.

Solution (in JAVA):

Solution:
import java.io.*;
import java.util.*;
import java.util.Map.Entry;
import java.lang.Math;
import java.math.BigInteger;

public class Problem {

	void solve() throws IOException {
		int n = rI();
		char[] sherlock = rS().toCharArray();
		char[] moriarty = rS().toCharArray();
		int[] digitCount = new int[10];
		TreeSet<Integer> st = new TreeSet<>();
		for(char d: moriarty){
			digitCount[d-'0']++;
			st.add(d-'0');
		}
		int ans = 0;
		for(int i=0;i<n;++i){
			if(st.ceiling(sherlock[i]-'0')!=null){
				digitCount[st.ceiling(sherlock[i]-'0')]--;
				if(digitCount[st.ceiling(sherlock[i]-'0')]==0){
					st.remove(st.ceiling(sherlock[i]-'0'));
				}
				
			}else{
				digitCount[st.ceiling(0)]--;
				if(digitCount[st.ceiling(0)]==0){
					st.remove(st.ceiling(0));
				}
				ans++;
			}
		}
		out.println(ans);
		for(char d: moriarty){
			digitCount[d-'0']++;
			st.add(d-'0');
		}
		ans = 0;
		for(int i=0;i<n;++i){
			if(st.higher(sherlock[i]-'0')!=null){
				digitCount[st.higher(sherlock[i]-'0')]--;
				if(digitCount[st.higher(sherlock[i]-'0')]==0){
					st.remove(st.higher(sherlock[i]-'0'));
				}
				ans++;
			}else{
				digitCount[st.ceiling(0)]--;
				if(digitCount[st.ceiling(0)]==0){
					st.remove(st.ceiling(0));
				}
			}
		}
		out.println(ans);
	}

	class SegmentTree {
		long[] t;

		SegmentTree(long[] a, int n) {
			t = new long[n * 4];
			build(a, 1, 1, n);
		}

		void build(long[] a, int v, int tl, int tr) {
			if (tl == tr) {
				t[v] = a[tl];
				return;
			}
			int tm = (tr + tl) / 2;
			build(a, 2 * v, tl, tm);
			build(a, 2 * v + 1, tm + 1, tr);
			t[v] = Math.max(t[2 * v], t[2 * v + 1]);
		}

		void update(int v, int tl, int tr, int pos, long value) {
			if (tl == tr) {
				t[v] = value;
				return;
			}
			int tm = (tl + tr) / 2;
			if (pos <= tm) {
				update(2 * v, tl, tm, pos, value);
			} else {
				update(2 * v + 1, tm + 1, tr, pos, value);
			}
			t[v] = Math.max(t[2 * v], t[2 * v + 1]);
		}

		long getMax(int v, int tl, int tr, int l, int r) {
			if (l > r) {
				return -INF;
			}
			if (tl == l && tr == r) {
				return t[v];
			}
			int tm = (tr + tl) / 2;
			long max1 = getMax(2 * v, tl, tm, l, Math.min(r, tm));
			long max2 = getMax(2 * v + 1, tm + 1, tr, Math.max(l, tm + 1), r);
			return Math.max(max1, max2);
		}
	}

	int checkBit(int mask, int bit) {
		return (mask >> bit) & 1;
	}

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

		new Problem().run();
	}

	boolean isLower(char a) {
		return ((int) a) >= 97 ? true : false;
	}

	long INF = Long.MAX_VALUE - 12345;

	int[][] STEPS = { { 0, 1 }, { 1, 0 }, { -1, 0 }, { 0, -1 } };

	BufferedReader in;
	PrintWriter out;
	StringTokenizer tok;
	Random rnd = new Random();
	static final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;

	Problem() throws FileNotFoundException {

		try {
			in = new BufferedReader(new FileReader("input.txt"));
			out = new PrintWriter("output.txt");
		} catch (Exception e) {
			in = new BufferedReader(new InputStreamReader(System.in));
			out = new PrintWriter(System.out);
		}

		tok = new StringTokenizer("");
	}

	long checkBit(long mask, int bit) {
		return (mask >> bit) & 1;
	}

	// ======================================================

	// ======================================================
	void run() throws IOException {
		solve();
		out.close();
	}

	char[] reverseCharArray(char[] arr) {
		char[] ans = new char[arr.length];
		for (int i = 0; i < arr.length; ++i) {
			ans[i] = arr[arr.length - i - 1];
		}
		return ans;
	}

	int sqrt(double m) {
		int l = 0;
		int r = 1000000000 + 9;
		int i = 1000;
		while (r - l > 1) {
			int mid = (r + l) / 2;
			if (mid * mid > m) {
				r = mid;
			} else {
				l = mid;
			}
		}
		return l;
	}

	int countPow(int m, int n) {
		int ans = 0;
		while (m % n == 0 && m > 0) {
			ans++;
			m /= n;
		}
		return ans;
	}

	long binPow(long a, long b) {
		if (b == 0) {
			return 1;
		}
		if (b % 2 == 1) {
			return a * binPow(a, b - 1);
		} else {
			long c = binPow(a, b / 2);
			return c * c;
		}

	}

	int gcd(int a, int b) {
		return b == 0 ? a : gcd(b, a % b);
	}

	long pow(long x, long k) {
		long ans = 1;
		for (int i = 0; i < k; ++i) {
			ans *= x;
		}
		return ans;
	}

	class Fenwik {

	}

	// ////////////////////////////////////////////////////////////////////

	String delimiter = " ";

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

	String rS() throws IOException {
		while (!tok.hasMoreTokens()) {
			String nextLine = readLine();
			if (null == nextLine)
				return null;

			tok = new StringTokenizer(nextLine);
		}

		return tok.nextToken(delimiter);
	}

	int rI() throws IOException {
		return Integer.parseInt(rS());
	}

	long rL() throws IOException {
		return Long.parseLong(rS());
	}

	double rD() throws IOException {
		return Double.parseDouble(rS());
	}

	int[] rA(int b) {
		int a[] = new int[b];
		for (int i = 0; i < b; i++) {
			try {
				a[i] = rI();
			} catch (IOException e) {
				e.printStackTrace();
			}
		}
		return a;
	}

	int[] readSortedIntArray(int size) throws IOException {
		Integer[] array = new Integer[size];

		for (int index = 0; index < size; ++index) {
			array[index] = rI();
		}
		Arrays.sort(array);

		int[] sortedArray = new int[size];
		for (int index = 0; index < size; ++index) {
			sortedArray[index] = array[index];
		}

		return sortedArray;
	}

	int[] sortedIntArray(int size, int[] array) throws IOException {
		for (int index = 0; index < size; ++index) {
			array[index] = rI();
		}
		Arrays.sort(array);

		int[] sortedArray = new int[size];
		for (int index = 0; index < size; ++index) {
			sortedArray[index] = array[index];
		}

		return sortedArray;
	}
}