#include <iostream>
#include <vector>
#include<iomanip>
#include<functional>
#include<algorithm>
#include<deque>
#include<set>
#include<queue>
#include<map>
using namespace std;
#define rep(i,n) for(int i = 0;i<n;i++)
#define req(i,n) for(int i = 1;i<=n;i++)
#define rrep(i,n) for(int i = n-1;i>=0;i--)
#define ALL(a) a.begin(),a.end()
typedef long long ll;
typedef double d;
typedef pair<int, int> P;
const int inf = 1 << 30;
struct liner {
	d a, b;
	liner(d a = 0, d b = 0): a(a), b(b) {}
	liner operator+(const liner& x)const {
		return liner(a + x.a, b + x.b);
	}liner operator-(const liner& x)const {
		return liner(a - x.a, b - x.b);
	}liner operator/(int x)const {
		return liner(a / x, b / x);
	}
};
int main() {
	int n, m, k,p,sum=0; cin >> n >> m >> k;
	vector<bool> f(n + 1, 0);
	rep(i, k) {
		cin >> p; f[p] = 1;
	}rep(i, n + 1) {
		if (f[i])sum++;
		else sum = 0;
		if (sum >= m) {
			cout << -1 << endl;
			return 0;
		}
	}vector<liner> dp(n + 1); liner S;
	rrep(i, n) {
		if (f[i]) dp[i] = liner(1, 0);
		else dp[i] = S / m + liner(0, 1);
		S = S+dp[i];
		if (i + m <= n) S = S - dp[i + m];
	}cout <<fixed<<setprecision(10) << dp[0].b / (1 - dp[0].a) << endl;
}
#include<bits/stdc++.h>
using namespace std;
const int N = 100005;
double ans;
int n,all,dkfjklasdhfklasdfklasdhfklasdh[15],dksfhjkasdfhasdhflasdhfkl[2][15],dsakfasdjkfhjklasdhf[15]={1};
char s[2][N];
bool Check(int x,int y){
	++dksfhjkasdfhasdhflasdhfkl[0][x],++dksfhjkasdfhasdhflasdhfkl[1][y];
	int X=0,Y=0;
	for(int i=1;i<10;++i)X+=i*dsakfasdjkfhjklasdhf[dksfhjkasdfhasdhflasdhfkl[0][i]],Y+=i*dsakfasdjkfhjklasdhf[dksfhjkasdfhasdhflasdhfkl[1][i]];
	--dksfhjkasdfhasdhflasdhfkl[0][x],--dksfhjkasdfhasdhflasdhfkl[1][y];return X>Y;
}
int main(){
	cin>>n>>s[0]+1>>s[1]+1,all=n*9;
	for(int _=0;_<2;++_)for(int i=1;i<5;++i)++dkfjklasdhfklasdfklasdhfklasdh[s[_][i]&15],++dksfhjkasdfhasdhflasdhfkl[_][s[_][i]&15],--all;
	for(int i=1;i<9;++i)dsakfasdjkfhjklasdhf[i]=dsakfasdjkfhjklasdhf[i-1]*10;
	for(int i=1;i<10;++i){
		for(int j=1;j<10;++j){
			if(dkfjklasdhfklasdfklasdhfklasdh[i]>=n||dkfjklasdhfklasdfklasdhfklasdh[j]>=n||(i==j&&dkfjklasdhfklasdfklasdhfklasdh[i]>=n-1))continue;
			if(Check(i,j)){
				if(i==j){
					ans+=(double)1.0*(1.0*(n-dkfjklasdhfklasdfklasdhfklasdh[i])/all)*(1.0*(n-dkfjklasdhfklasdfklasdhfklasdh[j]-1)/(all-1));
				}
				else{
					ans+=(double)1.0*(1.0*(n-dkfjklasdhfklasdfklasdhfklasdh[i])/all)*(1.0*(n-dkfjklasdhfklasdfklasdhfklasdh[j])/(all-1));
				}
			}
		}
	}
	printf("%.6lf",ans);
}