以下程序的运行结果是()#include iostream

以下程序的运行结果是()#include iostream

int func(int n)

{

if(n==1) return 1;

else return (n*func(n-1));

}

int main()

{

int x;

x=fun(3);

coutxendl;

}

A.5

B.6

C.7

D.8

正确答案:6

猜你喜欢