| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 70724 | 张智博 | 阿克曼函数 | Python3 | Compile Error | 0 MS | 0 KB | 420 | 2024-04-17 21:23:55 |
#include <iostream> using namespace std; int ackermann(int m, int n) { if (m == 0) { return n + 1; } else if (m > 0 && n == 0) { return ackermann(m - 1, 1); } else if (m > 0 && n > 0) { return ackermann(m - 1, ackermann(m, n - 1)); } } int main() { int m, n; cin >> m >> n; int result = ackermann(m, n); cout << result << endl; return 0; }
File "Main.py", line 2
using namespace std;
^
SyntaxError: invalid syntax