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

求证(编译出错)

Posted by 306565318 at 2008-10-14 21:03:32 on Problem 1005
#include<iostream>
using namespace std;
void main()
{
	int n,year[200];
	float x,y;
	cin>>n;
	for(int i=0;i<n;i++)
	{
		cin>>x>>y;
		if((x==0&&y==0)||y<0)
			return;
		float s=3.1415926*(x*x+y*y);
		year[i]=int(s/100)+1;
	}
	for(int k=0;k<n;k++)
	{
		cout<<"Property "<<k+1<<": This property will begin eroding in year "<<year[k]<<'.'<<endl;
	}
	cout<<"END OF OUTPUT."<<endl;;
}

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