← 查看本卷题目
组合题6 个小题
已作答 0 / 6
#include <iostream>#include <cmath>using namespace std; int customFunction(int a, int b) {    if (b == 0) {        return a;    }    return a + customFunction(a, b-1);} int main() {    int x, y;    cin >> x >> y;    int result = customFunction(x, y);    cout << pow(result, 2) << endl;    return 0;} 
第 32 题单选题原卷 4 分

(4 分)若将 customFunction 函数改为 return a + customFunction(a-1, b-1);,并输入 3 3,则程序的最终输出为( )。

填写答案