Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
请高手看下,为什么不能AC啊,但运行可以啊#include<iostream> #include<iomanip> using namespace std; int main() { float sum=0; float ave=0; float a[12]; for(int i=0;i<12;i++) { cin>>setiosflags(ios::fixed)>>setprecision(2)>>a[i]; sum+=a[i]; } ave=sum/12; cout<<setiosflags(ios::fixed)<<setprecision(2)<<ave; return 0; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator