Run ID | 作者 | 问题 | 语言 | 测评结果 | 分数 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|---|
105124 | 曾煦翔 | 棋子移动 | C++ | 编译错误 | 0 | 0 MS | 0 KB | 481 | 2023-10-05 10:54:13 |
#include<iostream> using namespace std; void tui(int a) { if(a == 4) { cout << "4,5-->9,10" << endl; cout << "8,9-->4,5" << endl; cout << "2,3-->8,9" << endl; cout << "7,8-->2,3" << endl; cout << "1,2-->7,8" << endl; } else { cout << a << "," << a + 1 << "-->" << 2 * a + 1 << 2 * (a + 1) << endl; cout << 2 * a - 1 << "," << 2 * a << "-->" << a << k + 1 << endl; tui(a - 1); } } int main() { int n; cin >> n; tui(n); }