from bisect import bisect_left, bisect_right n, m, c = map(int, input().split()) a = list(map(int, input().split())) b = list(map(int, input().split())) a.sort() b.sort() ALL = n*m good = 0 for v in a: good += m - bisect_right(b, c//v) print(good/ALL)