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

Re:为什么还是错的?help me !!附程序

Posted by songzhichao at 2009-09-11 19:01:46 on Problem 2583
In Reply To:Re:为什么还是错的?help me !!附程序 Posted by:cancel at 2005-10-05 22:39:25
> #include<iostream.h>
> 
> void caculate(int f0,int f1,int f2)
> {
> 	int a,b,c,f3,f4,f5;
> 	c=f0;
> 	a=(f0-2*f1+f2)/2;
> 	b=(-3*f0+4*f1-f2)/2;
> 	f3=9*a+3*b+c;
> 	f4=16*a+4*b+c;
> 	f5=25*a+5*b+c;
>     cout<<f3<<"  "<<f4<<"  "<<f5<<endl;
> }
> 	
> 
> 
> int main()
> {
> 	int f0,f1,f2,n;
> 	n=0;
> 	while(n<100)
> 	{
> 		cin>>f0>>f1>>f2;
> 		caculate(f0,f1,f2);
> 		n++;
> 	}
> 
> 	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