結果
| 問題 |
No.250 atetubouのzetubou
|
| コンテスト | |
| ユーザー |
沙耶花
|
| 提出日時 | 2022-03-17 20:59:11 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 53 ms / 5,000 ms |
| コード長 | 599 bytes |
| コンパイル時間 | 3,867 ms |
| コンパイル使用メモリ | 250,940 KB |
| 最終ジャッジ日時 | 2025-01-28 10:03:39 |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 20 |
ソースコード
#include <stdio.h>
#include <bits/stdc++.h>
#include <atcoder/all>
using namespace atcoder;
using mint = modint1000000007;
using namespace std;
#define rep(i,n) for(int i=0;i<(n);i++)
#define Inf 1000000000000005
long long dp[3005][3505];
int main(){
dp[0][0] = 1;
rep(i,3004){
rep(j,3004){
if(dp[i][j]){
dp[i+1][j] = min((long long)Inf,dp[i][j]+dp[i+1][j]);
dp[i+1][j+1] = min((long long)Inf,dp[i][j]+dp[i+1][j+1]);
}
}
}
int q;
cin>>q;
rep(_,q){
long long D,X,T;
cin>>D>>X>>T;
if(dp[D+X-1][D-1]<=T)cout<<"AC"<<endl;
else cout<<"ZETUBOU"<<endl;
}
return 0;
}
沙耶花