結果

問題 No.1801 Segment Game
ユーザー seven_threeseven_three
提出日時 2022-01-07 22:10:02
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 697 bytes
コンパイル時間 797 ms
コンパイル使用メモリ 92,260 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-04-26 20:51:49
合計ジャッジ時間 3,953 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
5,248 KB
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 AC 252 ms
5,376 KB
testcase_08 AC 248 ms
5,376 KB
testcase_09 WA -
testcase_10 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
#include <algorithm>
#include <vector>
#include <iomanip>
#include <cmath>
#include <stdio.h>
#include <queue>
#include <deque>
#include <cstdio>
#include <set>
#include <map>
#include <bitset>
#include <stack>
#include <cctype>
using namespace std;
int main() {
	int t;
	cin >> t;
	for (int i = 0; i < t; i++) {
		long long h, w, d;
		cin >> h >> w >> d;
		bool bo = false;
		if (!bo && h % 2 == 0 && w <= d) {
			cout << "N" << endl;
			bo = true;
		}
		if (!bo && w % 2 == 0 && h <= d) {
			cout << "N" << endl;
			bo = true;
		}
		if (!bo && h * h + w * w <= d * d) {
			cout << "N" << endl;
			bo = true;
		}
		if (!bo) {
			cout << "S" << endl;
		}
	}
}
0