結果
| 問題 |
No.250 atetubouのzetubou
|
| コンテスト | |
| ユーザー |
femto
|
| 提出日時 | 2016-01-16 18:09:01 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 636 bytes |
| コンパイル時間 | 464 ms |
| コンパイル使用メモリ | 60,412 KB |
| 実行使用メモリ | 6,948 KB |
| 最終ジャッジ日時 | 2024-09-19 20:13:46 |
| 合計ジャッジ時間 | 3,874 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | RE * 20 |
ソースコード
#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
using namespace std;
typedef long long ll;
const int MAX = 5000;
const ll MOD = ll(1e9 + 7);
ll c[MAX][MAX];
int main(){
cin.tie(0);
ios::sync_with_stdio(false);
for(int i = 0; i < MAX; i++) {
for(int j = 0; j < MAX; j++) {
if(j == 0 || i == j) {
c[i][j] = 1;
}
else {
c[i][j] = (c[i - 1][j - 1] + c[i - 1][j]) % MOD;
}
}
}
ll q;
cin >> q;
for(int loop = 0; loop < q; loop++) {
ll d, x, t;
cin >> d >> x >> t;
if(c[x + d - 1][d - 1] <= t) {
cout << "AC" << endl;
}
else {
cout << "ZETUBOU" << endl;
}
}
}
femto