题目地址:http://codevs.cn/problem/1023/ 分析: 水题 代码: var a,b:array[1..100] of real; n,t:real; i,z:longint; begin read(z); for i:=1 to z do read(a[i],b[i]); n:=0; for i:=1 to z do n:=n+a[i]*b[i]; t:=0; for i:=1 to z do t:=t+a[i]; write(n/t:0:2); end.