-->
当前位置:首页 > 题库

单选题:In the following function, what is the ending condition of recur

Luz5年前 (2021-05-10)题库2518
In the following function, what is the ending condition of recursive programming?
```
int xFunction(int n)
{
if (n == 1) return 1;
else return n + xFunction(n - 1);
}
```



A.n is 1.
B.n is greater than 1.
C.n is less than 1.
D.no base case.


答案:A