結果
| 問題 |
No.208 王将
|
| コンテスト | |
| ユーザー |
bal4u
|
| 提出日時 | 2019-06-24 06:32:54 |
| 言語 | C (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 292 bytes |
| コンパイル時間 | 1,421 ms |
| コンパイル使用メモリ | 27,136 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-12-31 07:07:25 |
| 合計ジャッジ時間 | 1,329 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 23 |
ソースコード
// yukicoder: No.208 王将
// 2019.6.24 bal4u
#include <stdio.h>
int main()
{
int x, y, x2, y2, ans;
scanf("%d%d%d%d", &x, &y, &x2, &y2);
if (x == y) {
if (x2 == y2 && x2 < x) ans = x + 1;
else ans = x;
} else if (x < y) ans = y;
else ans = x;
printf("%d\n", ans);
return 0;
}
bal4u