| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 148795 | 杨润东 | 14兔子问题 | C++ | Wrong Answer | 0 MS | 272 KB | 544 | 2026-02-28 20:02:09 |
#include <iostream> #include <vector> using namespace std; int main() { int months = 8; vector<long long> young(months + 1, 0); vector<long long> small(months + 1, 0); vector<long long> adult(months + 1, 0); young[1] = 1; for (int month = 2; month <= months; month++) { young[month] = adult[month - 1]; small[month] = young[month - 1]; adult[month] = small[month - 1] + adult[month - 1]; } cout << young[8] << " " << small[8] << " " << adult[8] << endl; return 0; }
------Input------
0
------Answer-----
13 8 13
------Your output-----
3 2 4