private sub command1_click()
dim s as integer
s=p(1)+p(2)+p(3)+p(4)
print s;
end sub
privte function p(n as integer)as integer
dim sum%,dim i%
for i=1 to n
sum=sum+i
next i
p=sum
end function
答案,20
求具体解析啊~
我意思是20这个答案怎么算出来的 不是解释题目意思
追答p(1)=1
p(2)=1+2=3
p(3)=1+2+3=6
p(4)=1+2+3+4=10
1+3+6+10=20