from bisect import * N, M, C = map(int, input().split()) A = list(map(int, input().split())) B = list(map(int, input().split())) A.sort() B.sort(reverse=True) j = 0 cnt = 0 for a in A: while j < M and a * B[j] > C: j += 1 cnt += j print(cnt / N / M)