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

第30题留个记号

Posted by 20092134 at 2011-07-17 02:33:58 on Problem 2601
#include<stdio.h>
int main()
{    double x,y,sum=0,c;
    int n,i;
	scanf("%d",&n);
	scanf("%lf%lf",&x,&y);
	i=n;
    while(i)
	{
		scanf("%lf",&c);
		sum+=c*i--;
	}
	printf("%.2f\n",(y+x*n-2*sum)/(n+1));
	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