以下代码中calculate( )函数属于哪个分类
Def calculate(number):
result = 0
i = 1
while i <= number:
result = result + i
i += 1
return result
Result = calculate(100)
Print('1~100的累积和为:', result)
A.无参无返回值函数
B.无参有返回值函数
C.有参无返回值函数
D.有参有返回值函数
正确答案是D