結果
| 問題 |
No.44 DPなすごろく
|
| ユーザー |
RCCW
|
| 提出日時 | 2017-02-14 21:51:01 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 317 bytes |
| コンパイル時間 | 709 ms |
| コンパイル使用メモリ | 58,708 KB |
| 実行使用メモリ | 8,448 KB |
| 最終ジャッジ日時 | 2024-12-29 22:32:10 |
| 合計ジャッジ時間 | 15,705 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 TLE * 1 |
| other | AC * 19 TLE * 1 |
ソースコード
#include <iostream>
#include <cstdio>
#include <vector>
#include <algorithm>
#include <utility>
using namespace std;
long long n;
long long cnt =0;
int dfs(int a){
if(a>n){return 0;}
if(a==n){cnt+=1; return 0;}
dfs(a+2);
//a=a-2;
dfs(a+1);
a=a-1;
return cnt;
}
int main() {
cin>>n;
cout<<dfs(0)<<endl;
}
RCCW