結果
| 問題 |
No.1491 銀将
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-05-20 03:44:53 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 40 ms / 1,000 ms |
| コード長 | 282 bytes |
| コンパイル時間 | 2,239 ms |
| コンパイル使用メモリ | 209,200 KB |
| 最終ジャッジ日時 | 2025-01-21 13:57:47 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 16 |
ソースコード
#pragma GCC optimize("O3")
#include <bits/stdc++.h>
using namespace std;
int main(void)
{
cin.tie(NULL);
ios::sync_with_stdio(false);
long long int res;
long long int n;
cin >> n;
res = (2*n + 1)*(2*n + 1);
res -= (4LL*(n-1) + 3);
cout << res << '\n';
return 0;
}