import bisect N, M , C = map(int, input().split()) A = list(map(int, input().split())) B = list(map(int, input().split())) B.sort() p = 0 for a in A: p += (M-bisect.bisect_right(B, C/a)) / (N*M) print(p)