Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

1003

Posted by 327009979 at 2008-12-05 19:32:09
#include<stdio.h>
int main()
{
	double x,sum=0.0;
        int n=2;
	do
	{
	scanf("%lf",&x);
	while(x-sum>0)
	{sum=sum+1.0/n;
	 n++;
	}
	printf("%d card(s)\n",n-2);
	}while(x!=0.00);
	return(0);
}
哪里错了?

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator