結果

問題 No.1822 Keima of Shogi
ユーザー yicode
提出日時 2023-06-13 14:38:30
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 372 bytes
コンパイル時間 1,533 ms
コンパイル使用メモリ 166,320 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-06-13 03:46:56
合計ジャッジ時間 2,260 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using Graph = vector<vector<int>>;
long long primeNumber(long long x) {
  bool fire = true;
  for(int i = 2; i <= sqrt(x); i++) {
    if(x % i == 0) {
      fire = false;
    }
  }
  return fire;
}
int main() {
  long long N; cin >> N;
  long long X = (N + 1) / 2;
  cout << (X + 1ll) * X / 2 << endl;
}
0