結果

問題 No.1754 T-block Tiling
ユーザー t98slidert98slider
提出日時 2021-11-21 14:29:19
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 343 bytes
コンパイル時間 2,776 ms
コンパイル使用メモリ 139,324 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-04 23:41:26
合計ジャッジ時間 3,252 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,380 KB
testcase_01 AC 2 ms
4,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<atcoder/all>
using namespace std;

int main(){
    int t,n;
    cin>>t;
    while(t--){
        cin>>n;
        vector<atcoder::modint998244353> dp(n+1);
        dp[0]=1;
        for(int i=0;i<n;i++){
            for(int j=i+1;j<=n;j++){
                dp[j]+=2*dp[i];
            }
        }
        cout<<dp[n].val()<<endl;
    }
}
0