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

bt题目 !!!

Posted by y_zou at 2005-11-05 10:52:04 on Problem 1450
用下面的code竟然也能AC

#include <iostream>
#include <cmath>

using namespace std;

int main()
{
	int a, i = 1;
	int m, n;
	float sum = 0;

	cin >> a;
	while(cin >> m >> n)
	{
		if(m % 2 == 1 && n % 2 == 1)
			sum = m * n + sqrt(2.0) - 1;
		else
			sum = m * n; 
		printf("Scenario #%d:\n", i++);
		printf("%.2f\n\n", sum);
	}
	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