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.DataInputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
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.InputMismatchException;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.PriorityQueue;
import java.util.Queue;
import java.util.Random;
import java.util.Scanner;
import java.util.StringTokenizer;
import java.util.TreeMap;
import java.util.TreeSet;

public class SuffixArray {
	private static InputStream stream;
	private static byte[] buf = new byte[1024];
	private static int curChar;
	private static int numChars;
	private static SpaceCharFilter filter;
	private static PrintWriter pw;
	private static long max = Long.MIN_VALUE;
	private static int mod = 1000000000 + 7;

	private static void soln() {
		int n=nextInt();
		String s1=nextLine();
		String s2=nextLine();
		int[] arr1=new int[10];
		int[] arr2=new int[10];
		for(int i=0;i<n;i++){
			int x=s2.charAt(i)-'0';
			arr1[x]++;
			arr2[x]++;
		}
		int ans1=0;
		int ans2=0;
		for(int i=0;i<n;i++){
			int x=s1.charAt(i)-'0';
			for(int j=x+1;j<10;j++){
				if(arr1[j]>0){
					ans1++;
					arr1[j]--;
					break;
				}
			}
			for(int j=x;j<10;j++){
				if(arr2[j]>0){
					ans2++;
					arr2[j]--;
					break;
				}
			}
		}
		pw.println(n-ans2);
		pw.println(ans1);
	}
	static class Hashing {
	   	 
	  	  static final int multiplier = 43;
	  	  static final Random rnd = new Random();
	  	  static final int mod1 = BigInteger.valueOf((int) (1e9 + rnd.nextInt((int) 1e9))).nextProbablePrime().intValue();
	  	  static final int mod2 = BigInteger.valueOf((int) (1e9 + rnd.nextInt((int) 1e9))).nextProbablePrime().intValue();
	  	  static final int invMultiplier1 = BigInteger.valueOf(multiplier).modInverse(BigInteger.valueOf(mod1)).intValue();
	  	  static final int invMultiplier2 = BigInteger.valueOf(multiplier).modInverse(BigInteger.valueOf(mod2)).intValue();
	 
	  	  long[] hash1, hash2;
	  	  long[] inv1, inv2;
	  	  int n;
	 
	  	  public Hashing(String s) {
	  	    n = s.length();
	  	    hash1 = new long[n + 1];
	  	    hash2 = new long[n + 1];
	  	    inv1 = new long[n + 1];
	  	    inv2 = new long[n + 1];
	  	    inv1[0] = 1;
	  	    inv2[0] = 1;
	 
	  	    long p1 = 1;
	  	    long p2 = 1;
	  	    for (int i = 0; i < n; i++) {
	  	      hash1[i + 1] = (hash1[i] + s.charAt(i) * p1) % mod1;
	  	      p1 = p1 * multiplier % mod1;
	  	      inv1[i + 1] = inv1[i] * invMultiplier1 % mod1;
	  	      hash2[i + 1] = (hash2[i] + s.charAt(i) * p2) % mod2;
	  	      p2 = p2 * multiplier % mod2;
	  	      inv2[i + 1] = inv2[i] * invMultiplier2 % mod2;
	  	    }
	  	  }
	 
	  	  public long getHash(int i, int len) {
	  	    return (((hash1[i + len] - hash1[i] + mod1) * inv1[i] % mod1) << 32)
	  	        + (hash2[i + len] - hash2[i] + mod2) * inv2[i] % mod2;
	  	  }
	  }  
	public static class Suffix implements Comparable<Suffix>{
		int index;
		int[] rank=new int[2];
		@Override
		public int compareTo(Suffix arg0){
			return (this.rank[0]==arg0.rank[0])?(this.rank[1]<arg0.rank[1]?-1:1):(this.rank[0]<arg0.rank[0]?-1:1);
		}	
	}
	private static int[] buildSuffix(String s,int n){
		Suffix[] arr=new Suffix[n];
		for(int i=0;i<n;i++)
			arr[i]=new Suffix();
		for(int i=0;i<n;i++){
			arr[i].index=i;
			arr[i].rank[0]=s.charAt(i)-'a';
			arr[i].rank[1]=((i+1)<n)?(s.charAt(i+1)-'a'):-1;
		}
		Arrays.sort(arr);
		//for(int i=0;i<n;i++)
			//System.out.print(arr[i].index);
		int[] ind=new int[n];
		for(int k=4;k<2*n;k=k*2){
			int rank=0;
			int p_rank=arr[0].rank[0];
			arr[0].rank[0]=rank;
			ind[arr[0].index]=0;
			for(int i=1;i<n;i++){
				if (arr[i].rank[0] == p_rank && arr[i].rank[1] == arr[i-1].rank[1]) {
	                p_rank = arr[i].rank[0];
	                arr[i].rank[0] = rank;
	            }
	            else{
	                p_rank = arr[i].rank[0];
	                arr[i].rank[0] = ++rank;
	            }
	            ind[arr[i].index] = i;
	        }
			for(int i=0;i<n;i++){
				int n_index=arr[i].index + k/2;
				arr[i].rank[1]=(n_index<n)?arr[ind[n_index]].rank[0] : -1;
			}
			Arrays.sort(arr);
		}
		int[] suffixArr=new int[n];
		for(int i=0;i<n;i++)
			suffixArr[i]=arr[i].index;
		return suffixArr;
	}
	private static long pow(long a, long b, long c) {
		if (b == 0)
			return 1;
		long p = pow(a, b / 2, c);
		p = (p * p) % c;
		return (b % 2 == 0) ? p : (a * p) % c;
	}
	
	private static class Pair implements Comparable<Pair> {
		String s;
		Hashing hash;
		public Pair(String a, Hashing x2) {
			s = a;
			hash = x2;
		}
		@Override
		public int compareTo(Pair arg0) {
			if(s.length()!=arg0.s.length())
				return s.length()-arg0.s.length();
			int l=0;
			int r=s.length()-1;
			while(l<=r){
				int mid=l+(r-l)/2;
				long hash1=this.hash.getHash(0,mid);
				long hash2=arg0.hash.getHash(0,mid);
				//System.out.println(l+" "+r+" "+hash1+" "+hash2+" "+mid);
				if(hash1==hash2)
					l=mid+1;
				else
					r=mid-1;
			}
			return s.charAt(r)-arg0.s.charAt(r);
		}
	}

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

	private static long max(long a, long b) {
		if (a > b)
			return a;
		return b;
	}

	private static long min(long a, long b) {
		if (a < b)
			return a;
		return b;
	}

	public static void main(String[] args) throws Exception {
		InputReader(System.in);
		pw = new PrintWriter(System.out);
		soln();
		pw.close();
	}

	public static void InputReader(InputStream stream1) {
		stream = stream1;
	}

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

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

	private static 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++];
	}

	private static int nextInt() {
		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;
	}

	private static long nextLong() {
		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;
	}

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

	private static String nextLine() {
		int c = read();
		while (isSpaceChar(c))
			c = read();
		StringBuilder res = new StringBuilder();
		do {
			res.appendCodePoint(c);
			c = read();
		} while (!isEndOfLine(c));
		return res.toString();
	}

	private static int[] nextIntArray(int n) {
		int[] arr = new int[n];
		for (int i = 0; i < n; i++) {
			arr[i] = nextInt();
		}
		return arr;
	}

	private static long[] nextLongArray(int n) {
		long[] arr = new long[n];
		for (int i = 0; i < n; i++) {
			arr[i] = nextLong();
		}
		return arr;
	}

	private static void pArray(int[] arr) {
		for (int i = 0; i < arr.length; i++) {
			System.out.print(arr[i] + " ");
		}
		System.out.println();
		return;
	}

	private static void pArray(long[] arr) {
		for (int i = 0; i < arr.length; i++) {
			System.out.print(arr[i] + " ");
		}
		System.out.println();
		return;
	}

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

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