結果
問題 | No.799 赤黒かーどげぇむ |
ユーザー |
![]() |
提出日時 | 2019-03-30 01:49:17 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 31 ms / 2,000 ms |
コード長 | 236 bytes |
コンパイル時間 | 229 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 10,752 KB |
最終ジャッジ日時 | 2024-11-07 01:51:53 |
合計ジャッジ時間 | 1,469 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
# -*- coding: utf-8 -*-a,b,c,d = map(int,input().split())ans = (b-a+1)*(d-c+1)if d < a or b < c:passelif a < c and d < b:ans -= d-c+1elif c < a and b < d:ans -= b-a+1else:ans -= min(b-c+1,d-a+1)print(ans)