标签:
Description
Input
Output
Sample Input
Sample Output
1 #include <stdio.h> 2 int main() 3 { 4 char s[100]; 5 double n,p,sum=0.0; 6 while(scanf("%s%lf%lf",s,&n,&p)!=EOF) 7 { 8 sum+=n*p; 9 10 } 11 printf("%.1lf\n",sum); 12 return 0; 13 }
标签:
原文地址:http://www.cnblogs.com/wangmengmeng/p/4552747.html