結果

問題 No.276 連続する整数の和(1)
ユーザー Rp7rfRp7rf
提出日時 2015-09-04 22:39:53
言語 C++11
(gcc 11.4.0)
結果
WA  
実行時間 -
コード長 181 bytes
コンパイル時間 1,035 ms
コンパイル使用メモリ 51,156 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-26 05:47:53
合計ジャッジ時間 2,183 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 2 ms
4,376 KB
testcase_02 WA -
testcase_03 AC 48 ms
4,376 KB
testcase_04 WA -
testcase_05 AC 373 ms
4,380 KB
testcase_06 WA -
testcase_07 AC 336 ms
4,376 KB
testcase_08 WA -
testcase_09 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
using namespace std;

int main(void){
  int n;
  cin>>n;
  unsigned long long sum = 0;
  for(int i = 1 ; i <= n ; i ++){
    sum += i;
  }
  cout<<sum%n<<endl;
}
0