首页 > 试题广场 >

#include using namesp...

[填空题]
#include<iostream>
using namespace std;
int n;
void f2(int x, int y);
void f1(int x, int y) {
    if (x < n)
        f2(y, x + y);
}
void f2(int x, int y) {
    cout << x << ' ';
    f1(y, x + y);
}
int main( ) {
    cin >> n;
    f1(0, 1);
    return 0;
    return 0;
}

输入:30
输出:1
最后还有个空格
发表于 2019-07-24 23:07:16 回复(0)