結果
問題 |
No.1406 Test
|
ユーザー |
![]() |
提出日時 | 2021-03-18 21:40:42 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 455 bytes |
コンパイル時間 | 1,689 ms |
コンパイル使用メモリ | 192,892 KB |
最終ジャッジ日時 | 2025-01-19 18:08:39 |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 22 |
ソースコード
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define rep(i,n) for(int i=0;i<n;i++) typedef pair<int,int>P; int main(){ int n; cin>>n; if(n==1){ cout<<101<<endl; return 0; } int a[n-1]; int sum=0; rep(i,n-1) { cin>>a[i]; sum+=a[i]; } int start=(n-sum%n)%n; //cout<<sum<<endl; //cout<<start<<endl; int cnt=0; while(start<=100){ start+=n; cnt++; } cout<<cnt<<endl; return 0; }