import sys from bisect import bisect_left def MI(): return map(int,sys.stdin.readline().rstrip().split()) def LI(): return list(map(int,sys.stdin.readline().rstrip().split())) N,M,C = MI() A,B = LI(),LI() B.sort() ans = 0 for a in A: x = (C//a)+1 index = bisect_left(B,x) ans += M-index print(ans/(N*M))