結果
| 問題 |
No.1940 Escape through + -
|
| ユーザー |
|
| 提出日時 | 2022-05-15 18:53:55 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 45 ms / 2,000 ms |
| コード長 | 328 bytes |
| コンパイル時間 | 1,603 ms |
| コンパイル使用メモリ | 167,904 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-09-16 22:30:41 |
| 合計ジャッジ時間 | 2,901 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 25 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i = 0; i < n; i++)
int main(){
int n;
long long m,s;
cin >> n >> m >> s;
vector<int>a(n);
rep(i,n)cin >> a[i];
long long tmp = 0;
rep(i,n)tmp += a[i];
if(abs(tmp - s) % m == 0)cout << "Yes" << endl;
else cout << "No" << endl;
return 0;
}