import bisect N,M,C = map(int,input().split()); Error = pow(10,-9) A = list(map(int,input().split())) B = list(map(int,input().split())) B.sort() ALL = N*M cnt = 0 for i in range(N): need = C/A[i] + Error ok = M - bisect.bisect_right(B,need) cnt += ok #print(ok) ans = cnt/ALL print(ans)