n = int(input()) a = list(map(int, input().split())) ans = 1000 b = 1000 for i in a: b *= (1000-i) b /= 1000**(n-1) print(ans-b)