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 |
为什莫我的错误阿那位高人指点指点 #include<iostream> #include<iomanip> using namespace std; int main() { long long int a ; double b,j; while(cin>>a) { b=0; for(j=1;j<=a;j++) b+=1.000/(2*j); cout<<"Cards Overhang"<<endl; cout<<setw(5)<<setiosflags(ios::right)<<a<<" "<< setw(8)<<setiosflags(ios::fixed)<<setprecision(3)<<setiosflags(ios::right) <<b<<endl; } return 0; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator