結果
| 問題 |
No.1603 Manhattan Social Distance
|
| コンテスト | |
| ユーザー |
eve__fuyuki
|
| 提出日時 | 2024-01-17 14:57:15 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 325 bytes |
| コンパイル時間 | 1,921 ms |
| コンパイル使用メモリ | 192,912 KB |
| 最終ジャッジ日時 | 2025-02-18 20:20:51 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 16 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
void fast_io() {
ios::sync_with_stdio(false);
std::cin.tie(nullptr);
}
int main() {
fast_io();
long long n, h, w;
cin >> n >> h >> w;
long long ans =
(h - 1) * (n / 2) * (n - n / 2) + (w - 1) * (n / 2) * (n - n / 2);
cout << ans << endl;
}
eve__fuyuki