結果
問題 |
No.799 赤黒かーどげぇむ
|
ユーザー |
![]() |
提出日時 | 2019-03-17 21:45:08 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 507 bytes |
コンパイル時間 | 1,059 ms |
コンパイル使用メモリ | 98,120 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-07-07 21:33:00 |
合計ジャッジ時間 | 1,255 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 13 WA * 7 |
ソースコード
#include <iomanip> #include <cmath> #include <sstream> #include <unordered_map> #include <unordered_set> #include <deque> #include <vector> #include <bitset> #include <queue> #include <set> #include <stack> #include <string> #include<iostream> #include<map> #include<algorithm> using namespace std; int main() { int a, b, c, d; cin >> a >> b >> c >> d; int ans = 0; for (int i = a; i <= b; i++) { if (i >= c) { ans--; } } ans += (b - a + 1)*(d - c + 1); cout << ans << endl; return 0; }