设有以下函数过程: Functiofun(m As Integer)As Integer Dimk As Integer,sum As Integer sum=0 Fork=m To 1 Step-2 sum=s

admin2010-11-20  27

问题 设有以下函数过程:
Functiofun(m As Integer)As Integer
     Dimk As Integer,sum As Integer
     sum=0
     Fork=m To 1 Step-2
       sum=sum+k
     Nextk
     fun=sum
   End Function
   若在程序中用语句s=fun(10)调用此函数,则s的值为______。

选项

答案30

解析
转载请注明原文地址:https://jikaoti.com/ti/jjg0FFFM
0

最新回复(0)