题解 | 中彩票的的概率
a=list(map(int,input().split())) b=list(map(float,input().split())) c=list(map(int,input().split())) dict={} n=1 for i in range(len(a)): dict[a[i]]=b[i] for m in c: if m in dict: n*=dict[m] else : continue print(round(n,3))
a=list(map(int,input().split())) b=list(map(float,input().split())) c=list(map(int,input().split())) dict={} n=1 for i in range(len(a)): dict[a[i]]=b[i] for m in c: if m in dict: n*=dict[m] else : continue print(round(n,3))
相关推荐