結果
問題 |
No.799 赤黒かーどげぇむ
|
ユーザー |
![]() |
提出日時 | 2019-07-05 19:51:34 |
言語 | C (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 227 bytes |
コンパイル時間 | 257 ms |
コンパイル使用メモリ | 27,904 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-09-22 04:41:42 |
合計ジャッジ時間 | 884 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 15 WA * 5 |
ソースコード
#include<stdio.h> int main() { int a, b, c, d; scanf("%d %d %d %d", &a, &b, &c, &d); int ans = (b - a + 1) * (d - c + 1); if (c > a)a = c; if (d < b)b = d; if (a < b) ans -= b - a + 1; printf("%d\n", ans); return 0; }